清理一些console

This commit is contained in:
luying
2022-01-12 09:43:26 +08:00
parent cad2ff5c9b
commit 885fd2d239
25 changed files with 56 additions and 64 deletions
@@ -6,7 +6,7 @@ import { difference } from 'underscore';
* @Last Modified by: 梁桐川
* @Last Modified time: 2021-08-27 17:47:56
*/
import { IT_TYPE, CURRENCY_BY_TYPE, CURRENCY_TYPE, COM_TEAM_STATUS, COM_BTL_CONST, CONSUME_TYPE, COM_BTL_QUALITY, MSG_SOURCE, QUALITY_TYPE, ROLE_SELECT, TASK_TYPE, KING_EXP_RATIO_TYPE, ITEM_CHANGE_REASON, getChannelType, CHANNEL_PREFIX } from './../../../consts';
import { IT_TYPE, CURRENCY_BY_TYPE, CURRENCY_TYPE, COM_TEAM_STATUS, COM_BTL_CONST, CONSUME_TYPE, COM_BTL_QUALITY, MSG_SOURCE, QUALITY_TYPE, ROLE_SELECT, TASK_TYPE, KING_EXP_RATIO_TYPE, ITEM_CHANGE_REASON } from './../../../consts';
import Role, { RoleModel } from '../../../db/Role';
import { STATUS } from '../../../consts/statusCode';
import { Application, BackendSession } from 'pinus';
@@ -24,7 +24,7 @@ import { pushComBtlTeamMsg, pushFriendTeamInviteMsg, pushNormalItemMsg, pushTeam
import { EXTERIOR } from '../../../pubUtils/dicParam';
import { getZeroPointD, getTimeFunD, getSeconds, nowSeconds } from '../../../pubUtils/timeUtil';
import { FriendParams } from '../../../domain/roleField/friend';
import { checkActivityTask, checkTask, checkTaskWithArgs, checkTaskWithGoods } from '../../../services/taskService';
import { checkTask, checkTaskWithGoods } from '../../../services/taskService';
import { gameData, getWarByBlueprtId } from '../../../pubUtils/data';
import { HeroModel } from '../../../db/Hero';
@@ -54,7 +54,7 @@ export class ComBattleHandler {
let teamCode = session.get('teamCode');
const { blueprtId, pub, ceLimit } = msg;
console.log('createTeam msg: ', msg);
// console.log('createTeam msg: ', msg);
// 检查藏宝图Id是否合法
if (!blueprtIdValid(blueprtId)) return resResult(STATUS.COM_BATTLE_BLUEPRT_INVALID);
const enoughBlueprt = await hasEnoughBlueprt(roleId, sid, blueprtId);
@@ -680,21 +680,13 @@ export class ComBattleHandler {
async sendTeamMsg(msg: { teamCode: string, type: number, content: string, targetRoleId: string, targetMsgCode: string }, session: BackendSession) {
let roleId = session.get('roleId');
let sid = session.get('sid');
let roleName = session.get('roleName');
let serverId = session.get('serverId');
const { teamCode, type, content, targetRoleId, targetMsgCode } = msg;
const result = await pushComBtlTeamMsg(teamCode, roleId, roleName, type, MSG_SOURCE.TEAM_ROLE, content, targetRoleId, targetMsgCode);
if (!result) {
return resResult(STATUS.WRONG_PARMS);
}
// 任务
await checkTaskWithArgs(roleId, sid, TASK_TYPE.CHAT, [getChannelType(CHANNEL_PREFIX.TEAM)]);
//活动任务
await checkActivityTask(serverId, sid, roleId, TASK_TYPE.CHAT, 1, { chatType: getChannelType(CHANNEL_PREFIX.TEAM) })
return resResult(STATUS.SUCCESS);
}