后台添加装备时可以选择武将穿上

This commit is contained in:
luying
2020-12-18 15:15:01 +08:00
parent b39c9bdc8b
commit f2c124a6e4
9 changed files with 592 additions and 267 deletions

View File

@@ -30,11 +30,11 @@ export default class UserController extends Controller {
public async createRoleData() {
const { ctx } = this;
const { hid, hlv, eid, ecount, itemid, itemcount, count, lv, skinid, selectedRowKeys: uids, optType } = ctx.request.body;
const { hid, hlv, eid, ecount, itemid, itemcount, count, lv, skinid, selectedRowKeys: uids, optType, ehid } = ctx.request.body;
if(optType == 'hero') {
ctx.body = await ctx.service.users.createHero(uids, hid, hlv);
} else if(optType == 'equip') {
ctx.body = await ctx.service.users.createEquip(uids, eid, ecount);
ctx.body = await ctx.service.users.createEquip(uids, eid, ecount, ehid);
} else if (optType == 'item') {
ctx.body = await ctx.service.users.createItem(uids, itemid, itemcount);
} else if (optType == 'gold') {