Add Role.display_name
This commit is contained in:
@@ -10,6 +10,7 @@ class Role(Base, mixins.TimestampsMixin):
|
||||
|
||||
id = types.Id()
|
||||
name = Column(String, index=True, unique=True, nullable=False)
|
||||
display_name = Column(String, nullable=False)
|
||||
description = Column(String, nullable=False)
|
||||
permissions = Column(ARRAY(String), index=True, server_default="{}", nullable=False)
|
||||
|
||||
|
@@ -36,6 +36,10 @@ class WorkspaceUser(object):
|
||||
def role(self):
|
||||
return self.workspace_role.role.name
|
||||
|
||||
@property
|
||||
def role_displayname(self):
|
||||
return self.workspace_role.role.display_name
|
||||
|
||||
@property
|
||||
def status(self):
|
||||
return "active"
|
||||
|
Reference in New Issue
Block a user