perf: 优化 acl 默认排序

This commit is contained in:
ibuler
2023-06-15 10:45:07 +08:00
parent c6e19a2989
commit e92c82568d
8 changed files with 13 additions and 14 deletions

View File

@@ -51,7 +51,7 @@ class BaseACL(JMSBaseModel):
objects = BaseACLQuerySet.as_manager()
class Meta:
ordering = ('priority', 'name')
ordering = ('priority', '-is_active', 'name')
abstract = True
def is_action(self, action):