提交 11b0aa3b 编写于 作者: B Bai 提交者: Jiangjie.Bai

fix: 修复操作应用/应用授权/acl等未记录日志的问题2

上级 4b1b63f7
...@@ -33,6 +33,9 @@ class LoginACL(BaseACL): ...@@ -33,6 +33,9 @@ class LoginACL(BaseACL):
class Meta: class Meta:
ordering = ('priority', '-date_updated', 'name') ordering = ('priority', '-date_updated', 'name')
def __str__(self):
return self.name
@property @property
def action_reject(self): def action_reject(self):
return self.action == self.ActionChoices.reject return self.action == self.ActionChoices.reject
......
...@@ -38,6 +38,9 @@ class LoginAssetACL(BaseACL, OrgModelMixin): ...@@ -38,6 +38,9 @@ class LoginAssetACL(BaseACL, OrgModelMixin):
unique_together = ('name', 'org_id') unique_together = ('name', 'org_id')
ordering = ('priority', '-date_updated', 'name') ordering = ('priority', '-date_updated', 'name')
def __str__(self):
return self.name
@classmethod @classmethod
def filter(cls, user, asset, system_user, action): def filter(cls, user, asset, system_user, action):
queryset = cls.objects.filter(action=action) queryset = cls.objects.filter(action=action)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册