Compare commits

...

2 Commits

2 changed files with 21 additions and 4 deletions

View File

@ -181,9 +181,18 @@ function this:topBar()
this.buyBtnText.text = Language[11868]
end
this.jiesuoBtn:GetComponent("Button").enabled = (not treasureState)
this.jiesuoBtnText.text = ((not treasureState) and Language[11869] or Language[11870])
local config = ConfigManager.GetConfigData(ConfigName.RechargeCommodityConfig,5001)
this.jiesuoBtnText.text = ((not treasureState) and MoneyUtil.GetMoneyUnitNameWithMoney(config.Price) or Language[11870])
-- this.dealBtnText.text = MoneyUtil.GetMoneyUnitNameWithMoney(config.Price)
Util.AddOnceClick(this.jiesuoBtn,function()
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.HeavenUnlockExtraRewardPanel,2)
PayManager.Pay(5001, function(id)
--this.RechargeSuccessFunc()
this.jiesuoBtnText.text = Language[11870]
Game.GlobalEvent:DispatchEvent(GameEvent.TreasureOfHeaven.RechargeQinglongSerectSuccess,false,false)
end)
--UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.HeavenUnlockExtraRewardPanel,2)
end)
local times = PrivilegeManager.GetPrivilegeRemainValue(1007)
this.box :GetComponent("Image").enabled = (not treasureState)

View File

@ -116,9 +116,17 @@ end
function this:SetTopBar()
treasureState = QinglongSerectTreasureManager.GetTreasureState() --秘宝礼包状态 0:可购买 1:已购买
this.jiesuoBtn:GetComponent("Button").enabled = (not treasureState)
this.jiesuoBtnText.text = ((not treasureState) and Language[11869] or Language[11870])
local config = ConfigManager.GetConfigData(ConfigName.RechargeCommodityConfig,5001)
this.jiesuoBtnText.text = ((not treasureState) and MoneyUtil.GetMoneyUnitNameWithMoney(config.Price) or Language[11870])
--this.jiesuoBtnText.text = ((not treasureState) and Language[11869] or Language[11870])
Util.AddOnceClick(this.jiesuoBtn, function()
UIManager.OpenPanel(UIName.GeneralPopup, GENERAL_POPUP_TYPE.HeavenUnlockExtraRewardPanel, 2)
--UIManager.OpenPanel(UIName.GeneralPopup, GENERAL_POPUP_TYPE.HeavenUnlockExtraRewardPanel, 2)
PayManager.Pay(5001, function(id)
--this.RechargeSuccessFunc()
this.jiesuoBtnText.text = Language[11870]
Game.GlobalEvent:DispatchEvent(GameEvent.TreasureOfHeaven.RechargeQinglongSerectSuccess,false,false)
end)
end)
local times = PrivilegeManager.GetPrivilegeRemainValue(1007)
this.box:GetComponent("Image").enabled = (not treasureState)