fix 直购礼包结束时间计算

back_recharge
wangyuan 2020-03-20 14:53:52 +08:00
parent b02f07e874
commit c208cc6bb7
1 changed files with 7 additions and 1 deletions

View File

@ -41,6 +41,7 @@ import com.ljsd.jieling.thread.task.RPCGmServerTask;
import com.ljsd.jieling.thread.task.RPCServerTask;
import com.ljsd.jieling.util.ConfigurableApplicationContextManager;
import com.ljsd.jieling.util.MessageUtil;
import com.ljsd.jieling.util.ToolsUtil;
import config.SDailyTasksConfig;
import config.SEndlessDifficulty;
import config.SGlobalSystemConfig;
@ -363,7 +364,11 @@ public class GlobalDataManaager implements IManager {
Map.Entry<Integer, Long> next = iterator.next();
if(next.getValue()<=now){
updateBuyTimesGoodsId.add(next.getKey());
refreshBagMap.put(next.getKey(),next.getValue() + SRechargeCommodityConfig.rechargeCommodityConfigMap.get(next.getKey()).getDailyUpdate() * TimeUtils.ONE_DAY);
long endTime = next.getValue();
while (endTime<now){
endTime += SRechargeCommodityConfig.rechargeCommodityConfigMap.get(next.getKey()).getDailyUpdate() * TimeUtils.ONE_DAY ;
}
refreshBagMap.put(next.getKey(),endTime);
update =true;
}
}
@ -379,6 +384,7 @@ public class GlobalDataManaager implements IManager {
user.getPlayerInfoManager().getRechargeInfo().clearCacheSendId();
user.getPlayerInfoManager().getRechargeInfo().setBuyGoodsTimes(buyGoodsTimes);
}
user.getPlayerInfoManager().getRechargeInfo().setRefreshBagMap(refreshBagMap);
}
}