mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-18 00:08:31 +00:00
fix: 修复同名用户登录时username设置问题
This commit is contained in:
@@ -247,8 +247,11 @@ class ConnectionTokenViewSet(ExtraActionApiMixin, RootOrgViewMixin, JMSModelView
|
||||
account = self._validate_perm(user, asset, account_name)
|
||||
if account.has_secret:
|
||||
data['input_secret'] = ''
|
||||
|
||||
if account.username != '@INPUT':
|
||||
data['input_username'] = ''
|
||||
if account.username == '@USER':
|
||||
data['input_username'] = user.username
|
||||
|
||||
ticket = self._validate_acl(user, asset, account)
|
||||
if ticket:
|
||||
|
Reference in New Issue
Block a user