注释掉一些log

This commit is contained in:
luying
2022-08-26 15:50:06 +08:00
parent 4b2e7d9d0f
commit 26b18b7ba0
17 changed files with 29 additions and 29 deletions

View File

@@ -62,7 +62,7 @@ export class RechargeMoneyHandler {
}
let notGetRecord = playerData.recordArr[0];
console.log('notGetRecord', JSON.stringify(notGetRecord));
// console.log('notGetRecord', JSON.stringify(notGetRecord));
await ActivityRechargeMoneyModel.addRecord(notGetRecord._id, item.id, `${item.gid}&${item.count}`);
let goods = await addItems(roleId, roleName, sid, [{ id: item.gid, count: item.count }], ITEM_CHANGE_REASON.RECHARGE_REWARD)

View File

@@ -157,7 +157,7 @@ export class NormalBattleHandler {
if (warInfo.warType == WAR_TYPE.COM_BATTLE) {
return resResult(STATUS.BATTLE_END_WRONG_TYPE);
}
console.log('####### warInfo.warType', warInfo.warType)
// console.log('####### warInfo.warType', warInfo.warType)
const BattleRecord = await BattleRecordModel.getBattleRecordByCode(battleCode, true);
if (!BattleRecord || BattleRecord.status != 0) {
@@ -255,7 +255,7 @@ export class NormalBattleHandler {
await challengeDailyGK(serverId, roleId, activityId, battleId)
}
} else if (warInfo.warType == WAR_TYPE.ACT_NEW_HERO_GK) {
console.log('##### warInfo.warType', warInfo.warType, isSuccess)
// console.log('##### warInfo.warType', warInfo.warType, isSuccess)
if (isSuccess) {
isFirst = await challengeNewHeroGK(serverId, roleId, activityId, battleId)
}

View File

@@ -133,7 +133,7 @@ export class GateActivityHandler {
obj.setMemberRecord(code, newMemberRecord);
let nextWeek = <number>getTimeFun().getAfterDayWithHour(7);
console.log('####### nextWeek', nextWeek)
// console.log('####### nextWeek', nextWeek)
let index = getGAIndexInPinus(this.aid);
// 更新redis数据
let myR = new Rank(REDIS_KEY.USER_GATE_ACTIVITY, { serverId, guildCode, index }, true);

View File

@@ -283,7 +283,7 @@ export class GuildTrainHandler {
let { trainInstances } = getArmyTrainJuDian(trainId);
let trainInfo = getGuildTrainGkInfo(trainId, hid);
let { progress } = findWhere(trainInstances, { hid });
console.log('progress = ' + progress);
// console.log('progress = ' + progress);
let guildTrain = await GuildTrainModel.findTrainInstanceBoxByIndex(code, trainId, hid, progress);
if (!guildTrain) {
res.releaseCallback();//解锁

View File

@@ -65,7 +65,7 @@ export async function getPlayerActivityData(activityId: number, serverId: number
}
let records = (playerSelfServerData && playerSelfServerData.challengeRecords) ? playerSelfServerData.challengeRecords : [];
for (let record of records) {
console.log(challengeBeginTime, challengeEndTime, record.time)
// console.log(challengeBeginTime, challengeEndTime, record.time)
if (record.time >= challengeBeginTime && record.time <= challengeEndTime) {
playerData.challengeCount++;
}

View File

@@ -75,7 +75,7 @@ export async function sendRankMail(data: TimeLimitRankData, serverId: number) {
let reward = data.getRewardByRank(rank);
if(reward) {
let guild = await GuildModel.findByCode(code, serverId, '+members');
console.log(guild.members)
// console.log(guild.members)
for(let roleId of guild.members) {
await sendMailByContent(MAIL_TYPE.TIME_LIMIT_RANK, roleId, {
params: [data.tabName,`${rank}`],

View File

@@ -39,7 +39,7 @@ export function getRandSeResult(id: number, randSe: RandSe[], originSe: RandSe[]
randomResult.push(...allRandom);
}
console.log('##### getRandSeResult', startId, effectCount)
// console.log('##### getRandSeResult', startId, effectCount)
for (let i = startId; i < effectCount; i++) {
if(randSe[i]) {

View File

@@ -620,7 +620,7 @@ export async function sendGuildCityDeclare(cityId: number, declareGuildCode: str
* @param serverId 区id
*/
export async function calWoodenHorseAndSend(serverId: number) {
console.log('calWoodenHorseAndSend');
// console.log('calWoodenHorseAndSend');
let obj = getRaceActivityObj();
return await obj.calServerHorses(serverId);
}

View File

@@ -143,7 +143,7 @@ export class WarReward {
// let warType = this.warInfo.warType;
if(this.isSuccess) { // 成功了才给固定奖励
console.log(this.fixReward)
// console.log(this.fixReward)
if(this.fixReward) this.handleFixReward(num);
if(this.conditionReward) this.handleConditionReward(num);
if(this.randomReward) await this.handleRandomReward(num);

View File

@@ -27,7 +27,7 @@ export default class Activity_Recharge_Money extends BaseModel {
//添加领取记录
public static async addRecord(_id: string, poolId: number, reward: string) {
console.log(_id, poolId, reward)
// console.log(_id, poolId, reward)
let result: ActivityRechargeMoneyModelType = await ActivityRechargeMoneyModel.findOneAndUpdate({ _id },
{ $set: { poolId, reward, rewardTime: new Date() } },
{ upsert: true, new: true }).lean(true);

View File

@@ -63,7 +63,7 @@ export default class Activity_Task_Pass extends BaseModel {
}
public static async receiveItems(serverId: number, activityId: number, roleId: string, roundIndex: number, receivedReward: ReceivedReward[]) {
console.log(receivedReward)
// console.log(receivedReward)
let result: ActivityTaskPassModelType = await ActivityTaskPassModel.findOneAndUpdate({ serverId, roleId, activityId, roundIndex},
{ $push: { receivedReward: { $each: receivedReward } }}, { upsert: true, new: true }).lean(true);
return result;

View File

@@ -57,7 +57,7 @@ export class FirstGiftPage {
items: FirstGiftItem[] = []; //奖励
constructor(data: FirstGiftDataInDb) {
console.log(data)
// console.log(data)
this.pageIndex = data.pageIndex;
this.targetMoney = data.targetMoney;
for (let obj of data.rewards) {

View File

@@ -255,16 +255,16 @@ export class PopUpShopPackage {
// 检查这个礼包是否可以推送
public checkPackageCanPush(conditionType: POP_UP_SHOP_CONDITION_TYPE) {
// 1. 达成条件类型是否符合
console.log('######### 3.5.1', this.conditionType, conditionType, this.conditionType != conditionType)
// console.log('######### 3.5.1', this.conditionType, conditionType, this.conditionType != conditionType)
if(this.conditionType != conditionType) return false;
// 2. 判断同类型是否是已经有在持续中的
console.log('######### 3.5.2', this.checkPushingItem, this.isPushing);
// console.log('######### 3.5.2', this.checkPushingItem, this.isPushing);
if(this.checkPushingItem && this.isPushing) return false;
// 3. 自然日内推送次数
console.log('######### 3.5.3', this.canLvUp, this.pushCnt, this.hasPushCnt, this.pushCnt != -1, this.hasPushCnt >= this.pushCnt)
// console.log('######### 3.5.3', this.canLvUp, this.pushCnt, this.hasPushCnt, this.pushCnt != -1, this.hasPushCnt >= this.pushCnt)
if(this.canLvUp == 1 && this.pushCnt != -1 && this.hasPushCnt >= this.pushCnt) return false;
// 4. 连续无视次数
console.log('######### 3.5.4', this.hasPassCnt, this.passCnt, this.passCnt > 0 && this.hasPassCnt >= this.passCnt)
// console.log('######### 3.5.4', this.hasPassCnt, this.passCnt, this.passCnt > 0 && this.hasPassCnt >= this.passCnt)
if(this.passCnt > 0 && this.hasPassCnt >= this.passCnt) return false;
return true;
@@ -408,18 +408,18 @@ export class PopShopItem {
}
public checkItemCanPush(conditionType: POP_UP_SHOP_CONDITION_TYPE, param: PopUpConditionParamInter) {
console.log('##### xyz?1', this.hasBoughtCnt >= this.buyCnt)
// console.log('##### xyz?1', this.hasBoughtCnt >= this.buyCnt)
if(this.hasBoughtCnt >= this.buyCnt) return false;
console.log('##### xyz?2', this.parent.getVipLv(), this.vipLv, this.parent.getVipLv() < this.vipLv)
// console.log('##### xyz?2', this.parent.getVipLv(), this.vipLv, this.parent.getVipLv() < this.vipLv)
if(this.parent.getVipLv() < this.vipLv || this.parent.getLv() < this.lv) return false;
console.log('##### xyz?3', this.parent.getLv(), this.lv, this.parent.getLv() < this.lv)
// console.log('##### xyz?3', this.parent.getLv(), this.lv, this.parent.getLv() < this.lv)
if(this.parent.getLv() < this.lv) return false;
console.log('##### xyz?4', this.checkKeyTime())
// console.log('##### xyz?4', this.checkKeyTime())
if(!this.checkKeyTime()) return false
console.log('##### xyz?5', this.canLvUp, this.hasPushCnt, this.pushCnt, this.pushCnt != -1, this.hasPushCnt >= this.pushCnt)
// console.log('##### xyz?5', this.canLvUp, this.hasPushCnt, this.pushCnt, this.pushCnt != -1, this.hasPushCnt >= this.pushCnt)
if(this.canLvUp == 0 && this.pushCnt != -1 && this.hasPushCnt >= this.pushCnt) return false
console.log('##### xyz?6', conditionType, this.conditionParam, param)
// console.log('##### xyz?6', conditionType, this.conditionParam, param)
switch(conditionType) {
case POP_UP_SHOP_CONDITION_TYPE.LV_TO:
return param.oldLv < this.conditionParam[0] && param.newLv >= this.conditionParam[0];

View File

@@ -150,7 +150,7 @@ export class RechargeMoneyData extends ActivityBase {
public initData(data: string) {
let dataObj: RechargeMoneyInDb = JSON.parse(data);
console.log(dataObj);
// console.log(dataObj);
for(let pool of dataObj.pool) {
let obj = new RechargeMoneyPool(pool);
this.pool.push(obj);

View File

@@ -75,7 +75,7 @@ export class RefreshShopItem {
let records = data.records ? data.records : [];
let buyRecords = records.filter(obj => {
let curRefTime = getZeroPointOfTime(obj.time, this.refreshType);
console.log(curRefTime, refZeroPoint)
// console.log(curRefTime, refZeroPoint)
return obj && obj.id === this.id && obj.pageIndex == this.pageIndex && curRefTime == refZeroPoint
});
this.buyCount = buyRecords.length;

View File

@@ -65,7 +65,7 @@ export class SignInData extends ActivityBase {
if(this.type == ACTIVITY_TYPE.SIGN_IN || this.type == ACTIVITY_TYPE.SIGN_IN_VIP) {
let time = getZeroPointOfTime(obj.time, SHOP_REFRESH_TYPE.DAILY, 0)
let today = getZeroPoint(SHOP_REFRESH_TYPE.DAILY, 0);
console.log('setPlayerRecords', time, today)
// console.log('setPlayerRecords', time, today)
if(day.indexOf(time) == -1 && time < today) {
this.todayIndex++;
day.push(time);

View File

@@ -100,11 +100,11 @@ export class UpdateRegionParams {
checkParams() {
if(!this.id || !this.name || !this.prefix || !isString(this.versionCode) || !isString(this.curVersion) || !isString(this.updateResUrl)) {
console.log('1111', !this.id, !this.name, !this.prefix, !isString(this.versionCode),!isString(this.curVersion), !isString(this.updateResUrl))
// console.log('1111', !this.id, !this.name, !this.prefix, !isString(this.versionCode),!isString(this.curVersion), !isString(this.updateResUrl))
return false
}
if(this.isOpen && (!this.maxPlayerCnt || !isArray(this.timers) || this.timers.length <= 0 || !isArray(this.activityGroupId) || this.activityGroupId.length <= 0 )) {
console.log('2222')
// console.log('2222')
return false
}
return true;
@@ -200,7 +200,7 @@ export class CreateServerParam {
}
checkParams() {
console.log('##### createNew', this.env, this.openTime, this.stopRegisterTime, this.hasOpenMail, this.hasCircleMail)
// console.log('##### createNew', this.env, this.openTime, this.stopRegisterTime, this.hasOpenMail, this.hasCircleMail)
if(!this.env || !this.openTime || !this.stopRegisterTime ) {
return false
}