后台添加修改密码、编辑、记录等功能
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { GMUserModel } from '@db/GMUser';
|
||||
import { GMUserGroupModel } from '@db/GMUserGroup'
|
||||
import { GMGroupModel } from '@db/GMGroup'
|
||||
import { GMRecordModel } from '@db/GMRecord'
|
||||
import { ApiModel } from '@db/Api';
|
||||
|
||||
module.exports = () => {
|
||||
@@ -50,9 +51,11 @@ module.exports = () => {
|
||||
};
|
||||
return;
|
||||
}
|
||||
console.log(user.uid, ctx.request.url, new Date());
|
||||
ctx.user = user;
|
||||
await next();
|
||||
if(ctx.request.method == "POST") {
|
||||
await GMRecordModel.createRecord(user?user.uid:0, ctx.request.url, JSON.stringify(ctx.request.body||{}), JSON.stringify(ctx.body||{}));
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user