This commit is contained in:
2020-07-28 21:51:28 +08:00
parent d6735bd7fa
commit 8604f7aff7
19 changed files with 824 additions and 778 deletions

View File

@@ -108,4 +108,32 @@ function DBUser.hadPermission(key)
return rolePermission[key] or false
end
function DBUser.isWhiteUser(userName, callback)
if isNilOrEmpty(userName) then
Utl.doCallback(callback, false)
return false
end
if DBUser.whiteNames == nil then
local url = Utl.urlAddTimes(joinStr(CLVerManager.self.baseUrl, "/whitList.json"))
WWWEx.get(
url,
CLAssetType.text,
function(content)
DBUser.whiteNames = json.decode(content)
Utl.doCallback(callback, DBUser.whiteNames[userName])
end,
function()
Utl.doCallback(callback, false)
end,
nil,
true,
1
)
return false
else
Utl.doCallback(callback, DBUser.whiteNames[userName])
return DBUser.whiteNames[userName]
end
end
return DBUser

View File

@@ -42,13 +42,20 @@ function CLLPStart.setLuasAtBegainning()
-- 日志监听
if ReporterMessageReceiver.self and ReporterMessageReceiver.self.gameObject then
-- if KKWhiteList.isWhiteName() then
ReporterMessageReceiver.self.gameObject:SetActive(false)
-- else
-- ReporterMessageReceiver.self.gameObject:SetActive(false)
-- end
end
DBUser.isWhiteUser(
Prefs.getUserName(),
function(iswhite)
if iswhite then
if ReporterMessageReceiver.self and ReporterMessageReceiver.self.gameObject then
ReporterMessageReceiver.self.gameObject:SetActive(true)
end
end
end
)
MyUtl.init(csSelf)
CLPanelManager.self.mainPanelName = "PanelMain"
@@ -191,8 +198,7 @@ function CLLPStart.doEnterGame()
NetProto.login(
{
phone = Prefs.getUserName(),
password = Prefs.getUserPsd(),
model=SystemInfo.deviceModel
password = Prefs.getUserPsd()
},
function(content, orgs)
if content.success then
@@ -266,24 +272,16 @@ CLLPStart.selectServer = function(callback)
Utl.doCallback(callback)
return
end
local url = Utl.urlAddTimes(PStr.b():a(CLVerManager.self.baseUrl):a("/whitList.json"):e())
WWWEx.get(
url,
CLAssetType.text,
function(content)
local map = json.decode(content)
if map[userName] then
DBUser.isWhiteUser(
userName,
function(iswhite)
if iswhite then
getPanelAsy("PanelSelectServer", onLoadedPanelTT, {callback = callback})
else
Utl.doCallback(callback)
end
end,
function()
Utl.doCallback(callback)
end,
nil,
true,
1
end
)
end

View File

@@ -239,7 +239,13 @@ end
function TRPCustList:resetFilters()
for i, v in ipairs(self.filters) do
v.selected = false
if v.list then
for j, f in ipairs(v.list) do
f.selected = false
end
else
v.value = ""
end
end
end

View File

@@ -69,12 +69,6 @@ function TRPOceanList:initFilters()
end
end
function TRPOceanList:resetFilters()
for i, v in ipairs(self.filters) do
v.selected = false
end
end
-- 设置数据
---@param paras _ParamTRPOceanList
function TRPOceanList:setData(paras)
@@ -152,7 +146,8 @@ function TRPOceanList:initCell(cell, data)
end
function TRPOceanList:onClickCell(cell, data)
getPanelAsy("PanelOrderDetail", onLoadedPanelTT, data)
--//TODO:
-- getPanelAsy("PanelOrderDetail", onLoadedPanelTT, data)
end
function TRPOceanList:refreshFilterBtnStatus()
@@ -218,7 +213,7 @@ function TRPOceanList:setEventDelegate()
"PanelComFilter",
onLoadedPanelTT,
{
title = "订单筛选",
title = "公海筛选",
callback = self:wrapFunc(self.onSetFilter),
queryKey = uiobjs.InputSeachKey.value,
defautFilter = self.filters
@@ -232,6 +227,18 @@ function TRPOceanList:setEventDelegate()
}
end
function TRPOceanList:resetFilters()
for i, v in ipairs(self.filters) do
if v.list then
for j, f in ipairs(v.list) do
f.selected = false
end
else
v.value = ""
end
end
end
function TRPOceanList:getFilterStr()
if not self.filters then
return ""
@@ -249,7 +256,7 @@ function TRPOceanList:getFilterStr()
elseif g.key == "createTime" then
--//TODO:
elseif g.key == "updateTime" then
--//TODO:
--//TODO:
end
end
return ret

View File

@@ -82,7 +82,13 @@ end
function TRPOrderList:resetFilters()
for i, v in ipairs(self.filters) do
v.selected = false
if v.list then
for j, f in ipairs(v.list) do
f.selected = false
end
else
v.value = ""
end
end
end

View File

@@ -972,7 +972,7 @@ MonoBehaviour:
target: {fileID: 0}
relative: 1
absolute: 0
updateAnchors: 0
updateAnchors: 1
mColor: {r: 0.8, g: 0.8, b: 0.8, a: 0.7058824}
mPivot: 4
mWidth: 204
@@ -2208,7 +2208,7 @@ MonoBehaviour:
target: {fileID: 0}
relative: 1
absolute: 0
updateAnchors: 0
updateAnchors: 1
mColor: {r: 0.6, g: 0.6, b: 0.6, a: 1}
mPivot: 4
mWidth: 144

View File

@@ -1 +1 @@
r8 (trCRM/resVer/Android/VerCtl/priority.ver8,0c7857a1831144f66d92c34bbc4c996d8 %trCRM/resVer/Android/VerCtl/other.ver8,b9c84be6298806fb21f27e9be837734d
r8 (trCRM/resVer/Android/VerCtl/priority.ver8,b661dc13be6252f388111b3e6948ab198 %trCRM/resVer/Android/VerCtl/other.ver8,b9c84be6298806fb21f27e9be837734d