This commit is contained in:
2020-02-18 10:15:02 +08:00
parent 5fb45fc57c
commit d4325e3016
18 changed files with 194 additions and 159 deletions

View File

@@ -11,7 +11,9 @@ namespace app\controller;
use think\App;
use think\exception\ValidateException;
use think\facade\View;
use think\facade\Cache;
use think\Validate;
use app\model\Config;
class Base {
@@ -62,6 +64,12 @@ class Base {
$this->app = $app;
$this->request = $this->app->request;
$config = Cache::get('system_config_data');
if (!$config) {
$config = Config::getConfigList($this->request);
Cache::set('system_config_data', $config);
}
View::assign('config', $config);
// 控制器初始化
$this->initialize();
}