diff --git a/Assets/ManagedResources/~Lua/Modules/Main/MainPanel.lua b/Assets/ManagedResources/~Lua/Modules/Main/MainPanel.lua index fc82eeb90e..e5e7a19de0 100644 --- a/Assets/ManagedResources/~Lua/Modules/Main/MainPanel.lua +++ b/Assets/ManagedResources/~Lua/Modules/Main/MainPanel.lua @@ -942,10 +942,6 @@ function this:OnShow() this.RefreshGiftBtnShow() -- 刷新一次编队战斗力 FormationManager.RefreshMainFormationPower() - - - -- 主界面time创建 - endTime = ActivityGiftManager.GetTaskEndTime(ActivityTypeDef.SupremeHero) this.TimeFormat() if not this._TimeCounter then this._TimeCounter = Timer.New(this.TimeFormat, 1, -1, true) diff --git a/Assets/ManagedResources/~Lua/Modules/Popup/RewardItemSingleShowPopup.lua b/Assets/ManagedResources/~Lua/Modules/Popup/RewardItemSingleShowPopup.lua index 25a04e886f..352d7334cc 100644 --- a/Assets/ManagedResources/~Lua/Modules/Popup/RewardItemSingleShowPopup.lua +++ b/Assets/ManagedResources/~Lua/Modules/Popup/RewardItemSingleShowPopup.lua @@ -325,8 +325,43 @@ function RewardItemSingleShowPopup:OnShow() for i = 1, #jumpDataList do if not RECHARGEABLE and (JumpConfig[jumpDataList[i]] == JumpType.firstRecharge or JumpConfig[jumpDataList[i]] == JumpType.ZhiZunJiangShi) then--(是否开启充值) else - local tempView = SubUIManager.Open(SubUIConfig.JumpViewNew, this.equipProGrid.transform, jumpDataList[i],heroConfig,self) - table.insert(this.jumpViewList,tempView) + local isShow = true + if JumpConfig[jumpDataList[i]] == JumpType.firstRecharge then + local id = ActivityGiftManager.IsActivityTypeOpen(ActivityTypeDef.FirstRecharge) + if id and id > 0 then + local configs = ConfigManager.GetAllConfigsDataByKey(ConfigName.ActivityRewardConfig,"ActivityId",id) + for i = 1,#configs do + if configs[i].Reward[1][1] == heroConfig.Id then + local mission = ActivityGiftManager.GetActivityInfo(ActivityTypeDef.FirstRecharge, configs[i].Id) + if mission.state ~= 1 then + isShow = true + else + isShow = false + end + break + end + end + else + isShow = false + end + elseif JumpConfig[jumpDataList[i]] == JumpType.ZhiZunJiangShi then + local id = ActivityGiftManager.IsActivityTypeOpen(ActivityTypeDef.SupremeHero) + if id and id > 0 then + if ActivityGiftManager.GetRewardState(42)~=3 then + local endTime = ActivityGiftManager.GetTaskEndTime(ActivityTypeDef.SupremeHero) + if endTime - PlayerManager.serverTime > 0 then + isShow = true + else + isShow = false + end + else + isShow = false + end + end + if isShow then + local tempView = SubUIManager.Open(SubUIConfig.JumpViewNew, this.equipProGrid.transform, jumpDataList[i],heroConfig,self) + table.insert(this.jumpViewList,tempView) + end end end this.scroll:GetComponent("RectTransform").sizeDelta = Vector2.New(912.8,717.6)