From 552055e6c5bdf6d0a1f93e34e8353d3dacc965b9 Mon Sep 17 00:00:00 2001 From: caoqianming Date: Wed, 9 Oct 2024 13:55:41 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20base=20=E5=90=AF=E5=8A=A8=E6=97=B6?= =?UTF-8?q?=E7=BC=93=E5=AD=98perms=5Falld=5Flist?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/system/apps.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/apps/system/apps.py b/apps/system/apps.py index 59d27b05..bf6e73d0 100755 --- a/apps/system/apps.py +++ b/apps/system/apps.py @@ -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()