mirror of https://github.com/openspug/spug
A 角色管理新增管理账户数量展示
parent
bdf01dcb23
commit
6f88298632
|
@ -73,6 +73,7 @@ class Role(models.Model, ModelMixin):
|
|||
tmp = super().to_dict(*args, **kwargs)
|
||||
tmp['page_perms'] = json.loads(self.page_perms) if self.page_perms else None
|
||||
tmp['deploy_perms'] = json.loads(self.deploy_perms) if self.deploy_perms else None
|
||||
tmp['used'] = self.user_set.count()
|
||||
return tmp
|
||||
|
||||
def __repr__(self):
|
||||
|
|
|
@ -20,8 +20,8 @@ class ComTable extends React.Component {
|
|||
title: '角色名称',
|
||||
dataIndex: 'name',
|
||||
}, {
|
||||
title: '权限个数',
|
||||
dataIndex: 'type',
|
||||
title: '关联账户',
|
||||
dataIndex: 'used',
|
||||
}, {
|
||||
title: '描述信息',
|
||||
dataIndex: 'desc',
|
||||
|
|
Loading…
Reference in New Issue