活动:修复累充
This commit is contained in:
@@ -279,12 +279,12 @@ export function _getActivityById(activityId: number) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export function _getActivitiesByType(serverId: number, type: number) {
|
export function _getActivitiesByType(serverId: number, type: number) {
|
||||||
let activityByType = pinus.app.get('activityByType')?.get(serverId)?.get(type)||[];
|
let activityByType = pinus.app.get('activityByType')?.get(serverId)?.get(type)??[];
|
||||||
let activities: Map<number, ActivityInRemote> = pinus.app.get('activities');
|
let activities: Map<number, ActivityInRemote> = pinus.app.get('activities');
|
||||||
let result: ActivityInRemote[] = [];
|
let result: ActivityInRemote[] = [];
|
||||||
for(let activityId of activityByType) {
|
for(let activityId of activityByType) {
|
||||||
let activity = activities.get(activityId);
|
let activity = activities.get(activityId);
|
||||||
if(activity && activity.beginTime <= Date.now() && activity.endTime >= Date.now()) {
|
if(activity && activity.isEnable) {
|
||||||
result.push(activity);
|
result.push(activity);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ export function rewardItemData(reward: Array<RewardParam>) {
|
|||||||
break;
|
break;
|
||||||
case ACTIVITY_RESOURCES_TYPE.GIFTPACKAGE://配置成礼包会立刻兑换,配置成物品会把礼包放入背包中
|
case ACTIVITY_RESOURCES_TYPE.GIFTPACKAGE://配置成礼包会立刻兑换,配置成物品会把礼包放入背包中
|
||||||
let goodData = gameData.goods.get(obj.id);//礼包物品
|
let goodData = gameData.goods.get(obj.id);//礼包物品
|
||||||
let giftPackageData = gameData.giftPackage.get(1)//gameData.giftPackage.get(goodData.gift);//礼包数据
|
let giftPackageData = gameData.giftPackage.get(goodData.gift);//礼包数据
|
||||||
let giftReward = rewardItemData(giftPackageData.reward)
|
let giftReward = rewardItemData(giftPackageData.reward)
|
||||||
goods = goods.concat(giftReward.goods)
|
goods = goods.concat(giftReward.goods)
|
||||||
heroes = heroes.concat(giftReward.heroes)
|
heroes = heroes.concat(giftReward.heroes)
|
||||||
|
|||||||
@@ -284,7 +284,7 @@ export async function settleOrderFromRedisPub(message: string) {
|
|||||||
|
|
||||||
let aliOrderID = params.order_id;
|
let aliOrderID = params.order_id;
|
||||||
|
|
||||||
let result = await settleOrder(order, params.sid);
|
let result = await settleOrder(order, parseInt(`${params.sid}`));
|
||||||
await UserOrderModel.saveOrderID(order.roleId, order.localOrderID, aliOrderID, JSON.stringify(result));
|
await UserOrderModel.saveOrderID(order.roleId, order.localOrderID, aliOrderID, JSON.stringify(result));
|
||||||
|
|
||||||
return true
|
return true
|
||||||
|
|||||||
@@ -67,7 +67,7 @@ export abstract class ActivityBase {
|
|||||||
this.interval = activityData.interval * 86400;
|
this.interval = activityData.interval * 86400;
|
||||||
|
|
||||||
this.type = activityData.type;
|
this.type = activityData.type;
|
||||||
console.log('今天是活动第几天', activityData.beginTime, new Date, this.todayIndex)
|
console.log('今天是活动第几天', activityData.beginTime, new Date, this.todayIndex, createTime, serverTime)
|
||||||
console.log('***** activityData', activityData.timeType, this.beginTime, this.endTime, this.interval, this.todayIndex, this.roundIndex, this.nextRefreshTime, this.effectDay)
|
console.log('***** activityData', activityData.timeType, this.beginTime, this.endTime, this.interval, this.todayIndex, this.roundIndex, this.nextRefreshTime, this.effectDay)
|
||||||
switch (activityData.timeType) {
|
switch (activityData.timeType) {
|
||||||
case ACTIVITY_TIME_TYPE.SERVER_OPEN_TIME: {
|
case ACTIVITY_TIME_TYPE.SERVER_OPEN_TIME: {
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ export class PayCallback37Data {
|
|||||||
uid: number; // 37用户id
|
uid: number; // 37用户id
|
||||||
game_id: number; // 游戏id
|
game_id: number; // 游戏id
|
||||||
fc_c_game_id: string; // 子游戏id
|
fc_c_game_id: string; // 子游戏id
|
||||||
sid: number; // 区服id
|
sid: string; // 区服id
|
||||||
actor_id: string; // 角色id
|
actor_id: string; // 角色id
|
||||||
order_id: string; // 37平台id
|
order_id: string; // 37平台id
|
||||||
order_no: string; // 我方订单id
|
order_no: string; // 我方订单id
|
||||||
|
|||||||
@@ -190,5 +190,9 @@
|
|||||||
{
|
{
|
||||||
"channel": "bantushanghai",
|
"channel": "bantushanghai",
|
||||||
"ip": "180.158.8.235"
|
"ip": "180.158.8.235"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"channel": "ly",
|
||||||
|
"ip": "101.228.7.167"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
Reference in New Issue
Block a user