战力:修改套装计算方式

This commit is contained in:
luying
2022-03-30 19:20:40 +08:00
parent 83dc974632
commit 170a1b96bc
6 changed files with 33 additions and 38 deletions

View File

@@ -305,8 +305,8 @@ export default class GMUsers extends Service {
}
let list = heroes.map(cur => {
let roleCe = roleMap.get(cur.roleId);
let attr = roleCe.attributes.filter(ccur => ccur.hid == cur.hid);
return {...cur, calculatedAttr: attr, env: ctx.app.config.realEnv}
let obj = roleCe.attributes.find(ccur => ccur.hid == cur.hid);
return {...cur, calculatedAttr: obj.attrs, env: ctx.app.config.realEnv}
})
return ctx.service.utils.resResult(STATUS.SUCCESS, { list, total })