🧪 test(debug): 新武将关卡添加重置功能
This commit is contained in:
@@ -2,6 +2,7 @@ import { Application, BackendSession, HandlerService, } from 'pinus';
|
|||||||
import { resResult } from '../../../pubUtils/util';
|
import { resResult } from '../../../pubUtils/util';
|
||||||
import { STATUS } from '../../../consts';
|
import { STATUS } from '../../../consts';
|
||||||
import { getPlayerNewHeroGKData } from '../../../services/activity/newHeroGKService';
|
import { getPlayerNewHeroGKData } from '../../../services/activity/newHeroGKService';
|
||||||
|
import { ActivityNewHeroGKModel } from '../../../db/ActivityNewHeroGK';
|
||||||
|
|
||||||
|
|
||||||
export default function (app: Application) {
|
export default function (app: Application) {
|
||||||
@@ -63,4 +64,11 @@ export class NewHeroGKHandler {
|
|||||||
return resResult(STATUS.SUCCESS);
|
return resResult(STATUS.SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async debugResetGK(msg: {}, session: BackendSession) {
|
||||||
|
const roleId = session.get('roleId');
|
||||||
|
await ActivityNewHeroGKModel.deleteMany({ roleId });
|
||||||
|
|
||||||
|
return resResult(STATUS.SUCCESS);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2112,6 +2112,7 @@ export function checkRouteParam(route: string, msg: any) {
|
|||||||
case "activity.monthlyFundHandler.debugSendMonthlyFundReward":
|
case "activity.monthlyFundHandler.debugSendMonthlyFundReward":
|
||||||
case "activity.bindPhoneHandler.debugSetGiftCodeStatus":
|
case "activity.bindPhoneHandler.debugSetGiftCodeStatus":
|
||||||
case 'activity.rebateHandler.debugSetRebate':
|
case 'activity.rebateHandler.debugSetRebate':
|
||||||
|
case 'activity.newHeroGKHandler.debugResetGK':
|
||||||
|
|
||||||
{
|
{
|
||||||
if (msg.magicWord !== DEBUG_MAGIC_WORD || !isDevelopEnv()) return false;
|
if (msg.magicWord !== DEBUG_MAGIC_WORD || !isDevelopEnv()) return false;
|
||||||
|
|||||||
Reference in New Issue
Block a user