后台添加清空账号功能
This commit is contained in:
@@ -27,6 +27,11 @@ export default class ActionPoint extends BaseModel {
|
||||
let result = await ActionPointModel.findOneAndUpdate({roleId}, { ap, refTime }, {upsert: true, new: true}).lean(lean);
|
||||
return result||{};
|
||||
}
|
||||
|
||||
public static async deleteAccount(roleId: string, lean = true) {
|
||||
let result = await ActionPointModel.deleteMany({roleId}).lean(lean);
|
||||
return result||{};
|
||||
}
|
||||
}
|
||||
|
||||
export const ActionPointModel = getModelForClass(ActionPoint);
|
||||
|
||||
Reference in New Issue
Block a user