mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-09-07 10:20:57 +00:00
perf: 设置默认的角色,系统用户角色添加权限 (#7898)
* perf: 修改 role handler * perf: 设置默认的角色,系统用户角色添加权限 * perf: authentication 还是放到系统中吧 Co-authored-by: ibuler <ibuler@qq.com> Co-authored-by: Jiangjie.Bai <32935519+BaiJiangJie@users.noreply.github.com>
This commit is contained in:
@@ -41,13 +41,3 @@ class PermissionViewSet(JMSModelViewSet):
|
||||
queryset = Permission.get_permissions(self.scope)
|
||||
queryset = queryset.prefetch_related('content_type')
|
||||
return queryset
|
||||
|
||||
|
||||
# class UserPermsApi(ListAPIView):
|
||||
# serializer_class = UserPermsSerializer
|
||||
# permission_classes = (IsValidUser,)
|
||||
#
|
||||
# def list(self, request, *args, **kwargs):
|
||||
# perms = RoleBinding.get_user_perms(request.user)
|
||||
# serializer = super().get_serializer(data={'perms': perms})
|
||||
# return Res
|
||||
|
Reference in New Issue
Block a user