feat: base 启动时缓存perms_alld_list
This commit is contained in:
parent
4b64903910
commit
bf2c330c0f
|
@ -12,4 +12,10 @@ class SystemConfig(AppConfig):
|
|||
from server.settings import get_sysconfig
|
||||
get_sysconfig(reload=True)
|
||||
cache.set('cache_sysconfig_need_task', False, timeout=30)
|
||||
|
||||
if cache.get('cache_alldperms_task', True):
|
||||
from apps.utils.permission import get_alld_perms
|
||||
get_alld_perms(update_cache=True)
|
||||
cache.set('cache_alldperms_task', False, timeout=30)
|
||||
|
||||
return super().ready()
|
||||
|
|
Loading…
Reference in New Issue