中间件

This commit is contained in:
win7 committed 2019-12-02 17:00:24 +08:00
1 parent 90a008612e
commit 5182111a65
6 files changed
+171 -3

No files matched your search

+6 -1
View File
@@ -6,6 +6,8 @@ namespace app;
use think\App;
use think\exception\ValidateException;
use think\Validate;
use app\middleware\UserLogin;
use app\middleware\Auth;
/**
* 控制器基础类
@@ -34,7 +36,10 @@ abstract class BaseController
* 控制器中间件
* @var array
*/
protected $middleware = [];
protected $middleware = [
UserLogin::class,
Auth::class,
];
/**
* 构造方法