base模块修改为全局中间件

This commit is contained in:
ap 2021-06-10 10:20:35 +08:00
parent 1f977001e5
commit 5f8036c365
2 changed files with 4 additions and 2 deletions

View File

@ -14,8 +14,10 @@
" name: 'xxx',",
" // 模块描述",
" description: 'xxx',",
" // 中间件",
" // 中间件,只对本模块有效",
" middlewares: [],",
" // 中间件,全局有效",
" globalMiddlewares: [],",
" } as ModuleConfig;",
"};"
],

View File

@ -11,6 +11,6 @@ export default (app: Application) => {
// 模块描述
description: '基础的权限管理功能,包括登录,权限校验',
// 中间件
middlewares: ['baseAuthorityMiddleware', 'baseLogMiddleware'],
globalMiddlewares: ['baseAuthorityMiddleware', 'baseLogMiddleware'],
} as ModuleConfig;
};