✨ feat(db): 修改role表数据库操作方式
This commit is contained in:
@@ -4,7 +4,7 @@ import { STATUS, GACHA_TYPE, HERO_QUALITY_TYPE, TASK_TYPE, ITEM_CHANGE_REASON, }
|
||||
import { gameData } from "../../../pubUtils/data";
|
||||
import { UserGachaModel } from "../../../db/UserGacha";
|
||||
import { refreshGacha, getGachaList, getVisitedHeroList, GachaPull, GachaResults, getDicGachaByGachaCnt, getNormalGachaId, getDicGachas } from "../../../services/activity/gachaService";
|
||||
import { RoleModel } from "../../../db/Role";
|
||||
import Role from "../../../db/Role";
|
||||
import { HeroModel } from "../../../db/Hero";
|
||||
import { handleCost, addItems } from "../../../services/role/rewardService";
|
||||
import { getZeroPointD, getTimeFun } from "../../../pubUtils/timeUtil";
|
||||
@@ -38,7 +38,7 @@ export class GachaHandler {
|
||||
async getGachaList(msg: {}, session: BackendSession) {
|
||||
const { } = msg;
|
||||
const roleId: string = session.get('roleId');
|
||||
let role = await RoleModel.findByRoleId(roleId, 'gachaHasGuide');
|
||||
let role = await Role.findByRoleId(roleId, 'gachaHasGuide');
|
||||
const list = await getGachaList(roleId);
|
||||
|
||||
return resResult(STATUS.SUCCESS, { hasInit: !!role.gachaHasGuide, list });
|
||||
|
||||
Reference in New Issue
Block a user