feat: dynamic attribute (#534)

This commit is contained in:
pycook
2024-06-07 10:29:32 +08:00
committed by GitHub
parent 1a774490ac
commit fa737e75c3
15 changed files with 205 additions and 96 deletions

View File

@@ -253,6 +253,9 @@ def is_app_admin(app=None):
if app is None:
return False
if hasattr(current_user, 'username') and current_user.username == 'worker':
return True
app_id = app.id
if 'acl_admin' in session.get("acl", {}).get("parentRoles", []):
return True