Merge branch 'dev_shenhe' into dev
This commit is contained in:
commit
0d916a96e8
@ -13,7 +13,10 @@ local LOCAL_DATA_KEY = {
|
|||||||
LAST_LOGIN_URL = "LAST_LOGIN_URL",
|
LAST_LOGIN_URL = "LAST_LOGIN_URL",
|
||||||
LAST_LOGIN_NAME = "LAST_LOGIN_NAME",
|
LAST_LOGIN_NAME = "LAST_LOGIN_NAME",
|
||||||
LAST_LOGIN_IP = "LAST_LOGIN_IP",
|
LAST_LOGIN_IP = "LAST_LOGIN_IP",
|
||||||
|
LAST_LOGIN_INFO = "LAST_LOGIN_INFO", -- 上一次登录成功的信息
|
||||||
|
LAST_LOGIN_TYPE = "LAST_LOGIN_TYPE", -- 上次登录类型 token不记录
|
||||||
ACCOUNT_INFO = "ACCOUNT_INFO",
|
ACCOUNT_INFO = "ACCOUNT_INFO",
|
||||||
|
SEND_QUEUE = "SEND_QUEUE",
|
||||||
SDK_LOGIN_TYPE = "SDK_LOGIN_TYPE",
|
SDK_LOGIN_TYPE = "SDK_LOGIN_TYPE",
|
||||||
|
|
||||||
NEED_UPDATE = "NEED_UPDATE", -- 需要更新
|
NEED_UPDATE = "NEED_UPDATE", -- 需要更新
|
||||||
@ -226,7 +229,7 @@ end
|
|||||||
|
|
||||||
function LocalData:getLastLoginInfo()
|
function LocalData:getLastLoginInfo()
|
||||||
local str = self:getString(LOCAL_DATA_KEY.LAST_LOGIN_INFO, "{}")
|
local str = self:getString(LOCAL_DATA_KEY.LAST_LOGIN_INFO, "{}")
|
||||||
local info = json.decode(str)
|
local info = json.decode(str) or {}
|
||||||
info.type = info.type or NetManager.LOGIN_TYPE.ANONYMOUS
|
info.type = info.type or NetManager.LOGIN_TYPE.ANONYMOUS
|
||||||
if type(info.type) == "number" then
|
if type(info.type) == "number" then
|
||||||
if info.type == SDKManager.BF_LOGIN_TYPE.GOOGLE then
|
if info.type == SDKManager.BF_LOGIN_TYPE.GOOGLE then
|
||||||
|
|||||||
@ -359,6 +359,7 @@ function First:requestAddress(callback, times, totalTimes)
|
|||||||
local serverResult = json.decode(rsp.Data)
|
local serverResult = json.decode(rsp.Data)
|
||||||
if serverResult then
|
if serverResult then
|
||||||
responded = true
|
responded = true
|
||||||
|
CS.BF.BFMain.IsShenhe = (serverResult.env == "audit" and CS.UnityEngine.Application.platform == CS.UnityEngine.RuntimePlatform.IPhonePlayer)
|
||||||
-- 如果已经成功过了 不作处理
|
-- 如果已经成功过了 不作处理
|
||||||
if self.hasReceiveAddrSuccess then
|
if self.hasReceiveAddrSuccess then
|
||||||
return
|
return
|
||||||
|
|||||||
@ -31,6 +31,9 @@ function ShopManager:triggerGiftPopUI(actType, actId)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function ShopManager:showGiftPopUI(actType, actId, onlySelf)
|
function ShopManager:showGiftPopUI(actType, actId, onlySelf)
|
||||||
|
if GFunc.isShenhe() then
|
||||||
|
return
|
||||||
|
end
|
||||||
if actType == PayManager.PURCHARSE_TYPE.ACT_GIFT and actId == GConst.ShopConst.FIRST_RECHARGE_ID then
|
if actType == PayManager.PURCHARSE_TYPE.ACT_GIFT and actId == GConst.ShopConst.FIRST_RECHARGE_ID then
|
||||||
UIManager:showUI("app/ui/shop/first_recharge_pop_ui")
|
UIManager:showUI("app/ui/shop/first_recharge_pop_ui")
|
||||||
else
|
else
|
||||||
|
|||||||
@ -11,6 +11,10 @@ function SideBarBaseCellComp:getModuleKey()
|
|||||||
return nil
|
return nil
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function SideBarBaseCellComp:getHasPurchase()
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
|
||||||
function SideBarBaseCellComp:getIsOpen()
|
function SideBarBaseCellComp:getIsOpen()
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
@ -159,6 +163,14 @@ function SideBarBaseCellComp:setVisible(visible)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function SideBarBaseCellComp:checkIsOpen()
|
||||||
|
-- 审核模式下大多数的带内购的侧边栏入口都不显示
|
||||||
|
if self:getHasPurchase() and GFunc.isShenhe() then
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
return self:getIsOpen()
|
||||||
|
end
|
||||||
|
|
||||||
function SideBarBaseCellComp:getIsVisible()
|
function SideBarBaseCellComp:getIsVisible()
|
||||||
return self.visible
|
return self.visible
|
||||||
end
|
end
|
||||||
|
|||||||
@ -5,6 +5,10 @@ function SideBarIdleCell:getModuleKey()
|
|||||||
return ModuleManager.MODULE_KEY.IDLE_DROP
|
return ModuleManager.MODULE_KEY.IDLE_DROP
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function SideBarIdleCell:getHasPurchase()
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
|
||||||
function SideBarIdleCell:getIsOpen()
|
function SideBarIdleCell:getIsOpen()
|
||||||
return DataManager.IdleData:getIsOpen()
|
return DataManager.IdleData:getIsOpen()
|
||||||
end
|
end
|
||||||
|
|||||||
@ -5,6 +5,10 @@ function SideBarSevenDaysCell:getModuleKey()
|
|||||||
return ModuleManager.MODULE_KEY.SEVEN_DAY
|
return ModuleManager.MODULE_KEY.SEVEN_DAY
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function SideBarSevenDaysCell:getHasPurchase()
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
|
||||||
function SideBarSevenDaysCell:getIsOpen()
|
function SideBarSevenDaysCell:getIsOpen()
|
||||||
return DataManager.SevenDayData:getIsOpen()
|
return DataManager.SevenDayData:getIsOpen()
|
||||||
end
|
end
|
||||||
|
|||||||
@ -430,7 +430,7 @@ function MainCityUI:refreshLeftBtns()
|
|||||||
CellClass = require(v)
|
CellClass = require(v)
|
||||||
self.sideBarClassMap[v] = CellClass
|
self.sideBarClassMap[v] = CellClass
|
||||||
end
|
end
|
||||||
if CellClass:getIsOpen() then
|
if CellClass:checkIsOpen() then
|
||||||
local cell = self.sideBarCellMap[v]
|
local cell = self.sideBarCellMap[v]
|
||||||
if cell == nil then
|
if cell == nil then
|
||||||
cell = self:addSideBarCellComp(v)
|
cell = self:addSideBarCellComp(v)
|
||||||
@ -510,7 +510,7 @@ function MainCityUI:refreshRightBtns()
|
|||||||
CellClass = require(v)
|
CellClass = require(v)
|
||||||
self.sideBarClassMap[v] = CellClass
|
self.sideBarClassMap[v] = CellClass
|
||||||
end
|
end
|
||||||
if CellClass:getIsOpen() then
|
if CellClass:checkIsOpen() then
|
||||||
local cell = self.sideBarCellMap[v]
|
local cell = self.sideBarCellMap[v]
|
||||||
if cell == nil then
|
if cell == nil then
|
||||||
cell = self:addSideBarCellComp(v)
|
cell = self:addSideBarCellComp(v)
|
||||||
@ -641,7 +641,7 @@ end
|
|||||||
|
|
||||||
function MainCityUI:refreshBounty()
|
function MainCityUI:refreshBounty()
|
||||||
local isOpen = DataManager.BountyData:getIsOpen()
|
local isOpen = DataManager.BountyData:getIsOpen()
|
||||||
if not isOpen or self.mainComp:getCurModuleType() == GConst.MainCityConst.MAIN_MODULE.DAILY_CHALLENGE then
|
if not isOpen or self.mainComp:getCurModuleType() == GConst.MainCityConst.MAIN_MODULE.DAILY_CHALLENGE or GFunc.isShenhe() then
|
||||||
self.bountyNode:setVisible(false)
|
self.bountyNode:setVisible(false)
|
||||||
self.bountyRewardSpine:getSkeletonGraphic().enabled = false
|
self.bountyRewardSpine:getSkeletonGraphic().enabled = false
|
||||||
return
|
return
|
||||||
@ -881,11 +881,11 @@ function MainCityUI:checkSideBarOpenStatus()
|
|||||||
for k, CellClass in pairs(self.sideBarClassMap) do
|
for k, CellClass in pairs(self.sideBarClassMap) do
|
||||||
local cell = self.sideBarCellMap[k]
|
local cell = self.sideBarCellMap[k]
|
||||||
if cell and cell:getIsActive() then
|
if cell and cell:getIsActive() then
|
||||||
if not CellClass:getIsOpen() then
|
if not CellClass:checkIsOpen() then
|
||||||
return self:refreshAllSideBars()
|
return self:refreshAllSideBars()
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
if CellClass:getIsOpen() then
|
if CellClass:checkIsOpen() then
|
||||||
return self:refreshAllSideBars()
|
return self:refreshAllSideBars()
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -900,7 +900,7 @@ function MainCityUI:checkMainPop()
|
|||||||
return
|
return
|
||||||
end
|
end
|
||||||
-- 检查功能弹窗
|
-- 检查功能弹窗
|
||||||
if DataManager.PlayerData:getIfCanShowModuleUnlock() then
|
if DataManager.PlayerData:getIfCanShowModuleUnlock() and not GFunc.isShenhe() then
|
||||||
ModuleManager.MaincityManager:showModuleUnlockUI()
|
ModuleManager.MaincityManager:showModuleUnlockUI()
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
@ -960,6 +960,10 @@ end
|
|||||||
|
|
||||||
-- 检查礼包(首充/章节/新手/助力/成长/金币顺序)
|
-- 检查礼包(首充/章节/新手/助力/成长/金币顺序)
|
||||||
function MainCityUI:checkGift()
|
function MainCityUI:checkGift()
|
||||||
|
-- 审核模式不弹礼包
|
||||||
|
if GFunc.isShenhe() then
|
||||||
|
return
|
||||||
|
end
|
||||||
-- 引导其间不处理
|
-- 引导其间不处理
|
||||||
if DataManager.TutorialData:getIsHaveTutorial() then
|
if DataManager.TutorialData:getIsHaveTutorial() then
|
||||||
return
|
return
|
||||||
|
|||||||
@ -41,7 +41,7 @@ function ShopComp:initTitlePage()
|
|||||||
self.subTitleSelectText2 = self.uiMap["shop_comp.title_node.btn_cell_2.select_text"]
|
self.subTitleSelectText2 = self.uiMap["shop_comp.title_node.btn_cell_2.select_text"]
|
||||||
self.subTitleIcon2 = self.uiMap["shop_comp.title_node.btn_cell_2.icon"]
|
self.subTitleIcon2 = self.uiMap["shop_comp.title_node.btn_cell_2.icon"]
|
||||||
self.subTitleBtn2 = self.uiMap["shop_comp.title_node.btn_cell_2"]
|
self.subTitleBtn2 = self.uiMap["shop_comp.title_node.btn_cell_2"]
|
||||||
|
|
||||||
self.subTitleText1:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_16)) -- 特惠商品
|
self.subTitleText1:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_16)) -- 特惠商品
|
||||||
self.subTitleSelectText1:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_16)) -- 特惠商品
|
self.subTitleSelectText1:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_16)) -- 特惠商品
|
||||||
self.subTitleText2:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_17)) -- 主要商品
|
self.subTitleText2:setText(I18N:getGlobalText(I18N.GlobalConst.SHOP_DESC_17)) -- 主要商品
|
||||||
@ -57,6 +57,10 @@ function ShopComp:initTitlePage()
|
|||||||
|
|
||||||
local safeHeight = SafeAreaManager:getNotchScreenHeight()
|
local safeHeight = SafeAreaManager:getNotchScreenHeight()
|
||||||
self.titleNode:setAnchoredPositionY(TITLE_POS - safeHeight)
|
self.titleNode:setAnchoredPositionY(TITLE_POS - safeHeight)
|
||||||
|
if GFunc.isShenhe() then
|
||||||
|
self.subTitleBtn2:setAnchoredPositionX(0)
|
||||||
|
self.subTitleBtn1:setVisible(false)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function ShopComp:refreshTitle()
|
function ShopComp:refreshTitle()
|
||||||
@ -80,6 +84,9 @@ function ShopComp:refreshTitle()
|
|||||||
end
|
end
|
||||||
|
|
||||||
function ShopComp:switchPage(page)
|
function ShopComp:switchPage(page)
|
||||||
|
if page == PAGE_DISCOUNT and GFunc.isShenhe() then
|
||||||
|
page = PAGE_MAIN
|
||||||
|
end
|
||||||
if self.page ~= page then
|
if self.page ~= page then
|
||||||
self.page = page
|
self.page = page
|
||||||
self.post = false
|
self.post = false
|
||||||
|
|||||||
@ -72,6 +72,21 @@ function TaskMainUI:initTaskList()
|
|||||||
end
|
end
|
||||||
sortTask(self.dailyTaskList)
|
sortTask(self.dailyTaskList)
|
||||||
sortTask(self.challengeTaskList)
|
sortTask(self.challengeTaskList)
|
||||||
|
-- 审核模式不显示战令任务
|
||||||
|
if GFunc.isShenhe() then
|
||||||
|
for i = #self.dailyTaskList, 1, -1 do
|
||||||
|
local task = self.dailyTaskList[i]
|
||||||
|
if task.lock then
|
||||||
|
table.remove(self.dailyTaskList, i)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
for i = #self.challengeTaskList, 1, -1 do
|
||||||
|
local task = self.challengeTaskList[i]
|
||||||
|
if task.lock then
|
||||||
|
table.remove(self.challengeTaskList, i)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function TaskMainUI:onClose()
|
function TaskMainUI:onClose()
|
||||||
|
|||||||
@ -827,7 +827,9 @@ function ShopData:getRp()
|
|||||||
if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.MALL, true) then
|
if not ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.MALL, true) then
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
|
if GFunc.isShenhe() then
|
||||||
|
return false
|
||||||
|
end
|
||||||
local isHotOpen = ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.MALL_DAILY, true)
|
local isHotOpen = ModuleManager:getIsOpen(ModuleManager.MODULE_KEY.MALL_DAILY, true)
|
||||||
-- 主要商品 每日特惠广告道具
|
-- 主要商品 每日特惠广告道具
|
||||||
local hotAdGoods = self:getMallDailyGoods() and self:getMallDailyGoods()[1]
|
local hotAdGoods = self:getMallDailyGoods() and self:getMallDailyGoods()[1]
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user