dev_chengFeng
jiaoyangna 2020-08-22 22:27:52 +08:00
parent 35899a49a4
commit fb4d9e0d45
4 changed files with 10 additions and 9 deletions

View File

@ -1338,12 +1338,12 @@ function this.TimeFormat()
end
--青龙秘宝
local QingLong = not not ActivityGiftManager.GetActivityTypeInfo(ActivityTypeDef.TreasureOfSomeBody)
if dynamicAct then
if QingLong then
local info = ActivityGiftManager.GetActivityTypeInfo(ActivityTypeDef.TreasureOfSomeBody)
info = info.endTime - PlayerManager.serverTime
info = math.floor(info/86400)
local tempTime = info.endTime - PlayerManager.serverTime
tempTime = math.floor(tempTime/86400)
if ActivityGiftManager.IsActivityTypeOpen(ActivityTypeDef.TreasureOfSomeBody) then
this.treasureOfSlText.text = info..""
this.treasureOfSlText.text = tempTime..""
end
end

View File

@ -97,7 +97,7 @@ function this.GetTrailWeekTime(msg)
end
function this.GetTimeStartToEnd()
local info= ActivityGiftManager.GetActivityInfoByType(this.activityId)
local info= ActivityGiftManager.GetActivityInfoByType(ActivityTypeDef.TreasureOfSomeBody)
if info then
local startTime= this.GetTimeShow(info.startTime)
local endtime= this.GetTimeShow(info.endTime)

View File

@ -41,9 +41,9 @@ function this.SetBasicValues(giftGoodsList)
local rechargeConfig = ConfigManager.GetConfigData(ConfigName.RechargeCommodityConfig, giftGoodsInfo.goodsId)
-- LogGreen("------充值活动-----------礼包类型:".. rechargeConfig.Type .." 礼包ID".. giftGoodsInfo.goodsId .." 已购:"
-- ..giftGoodsInfo.buyTimes.." 开始:"..giftGoodsInfo.startTime.." 结束:"
-- ..giftGoodsInfo.endTime .. " 可购(没卵用)" .. giftGoodsInfo.dynamicBuyTimes)
LogGreen("------充值活动-----------礼包类型:".. rechargeConfig.Type .." 礼包ID".. giftGoodsInfo.goodsId .." 已购:"
..giftGoodsInfo.buyTimes.." 开始:"..giftGoodsInfo.startTime.." 结束:"
..giftGoodsInfo.endTime .. " 可购(没卵用)" .. giftGoodsInfo.dynamicBuyTimes)
if giftGoodsInfoList[rechargeConfig.Type] then

View File

@ -43,13 +43,14 @@ function this:BindEvent()
if AppConst.isSDKLogin then
PayManager.Pay({ Id = curGiftId })
else
LogBlue("curGiftId:"..curGiftId)
NetManager.RequestBuyGiftGoods(curGiftId, function()
FirstRechargeManager.RefreshAccumRechargeValue(curGiftId)
CheckRedPointStatus(RedPointType.GrowthPackage)--成长礼包的红点检测
rechargeData.dynamicBuyTimes = rechargeData.dynamicBuyTimes - 1
--判断可购买次数是否为零,是剔除礼包信息
-- for i = 1, #curGiftList do
if rechargeData.dynamicBuyTimes == 0 then
if rechargeData.dynamicBuyTimes < 1 then
OperatingManager.SetHadBuyGoodsId({curGiftId})
OperatingManager.RemoveItemInfoByType(GoodsTypeDef.DirectPurchaseGift, curGiftId)
end