mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-07-03 10:06:32 +00:00
perf: luna 页面获取资产系统用户按 name 排序
This commit is contained in:
parent
a45f581b0e
commit
102d3b590b
@ -121,7 +121,7 @@ class UserGrantedAssetSystemUsersForAdminApi(ListAPIView):
|
|||||||
system_user_ids = system_users_with_actions.keys()
|
system_user_ids = system_users_with_actions.keys()
|
||||||
system_users = SystemUser.objects.filter(id__in=system_user_ids)\
|
system_users = SystemUser.objects.filter(id__in=system_user_ids)\
|
||||||
.only(*self.serializer_class.Meta.only_fields) \
|
.only(*self.serializer_class.Meta.only_fields) \
|
||||||
.order_by('priority')
|
.order_by('name')
|
||||||
system_users = list(system_users)
|
system_users = list(system_users)
|
||||||
for system_user in system_users:
|
for system_user in system_users:
|
||||||
actions = system_users_with_actions.get(system_user.id, 0)
|
actions = system_users_with_actions.get(system_user.id, 0)
|
||||||
|
Loading…
Reference in New Issue
Block a user