装备替换

This commit is contained in:
mamengke01
2020-12-30 15:02:37 +08:00
parent 552534b585
commit ac2fc62f69
4 changed files with 6 additions and 9 deletions
-5
View File
@@ -226,11 +226,6 @@ export default class Hero extends BaseModel {
let result: HeroType = await HeroModel.findOneAndUpdate({roleId, hid}, {$set:heroUpdate}, {new: true}).select(select).lean(lean);
return result;
}
public static async getHeroEquip(roleId: string, hid: number, lean = true) {
let result: HeroType = await HeroModel.findOne({ roleId, hid }).populate('ePlace.equip').lean(lean);
return result;
}
public static async unloadHeroAndEquip(roleId: string, hid: number, id: number, lean = true) {
const hero: HeroType = await HeroModel.findOneAndUpdate(