This commit is contained in:
2020-07-28 21:02:59 +08:00
parent 5a53995fff
commit 8c38fea011
120 changed files with 7097 additions and 1930 deletions

View File

@@ -72,8 +72,10 @@ function CLLMainLua.setAndroidStatusBar()
if CLPathCfg.self.platform ~= "Android" then
return
end
local mode = string.upper( SystemInfo.deviceModel)
if string.find(mode, "HUAWEI") then
local mode = SystemInfo.deviceModel
if string.find(string.upper(mode), "HUAWEI")
and "HUAWEI BAC-TL00" ~= mode -- 齐川的手机
then
AndroidStatusBar.setFlags(AndroidStatusBar.WINDOW_FLAG_FORCE_NOT_FULLSCREEN)
AndroidStatusBar.setColor(AndroidStatusBar.DEFAULT_BACKGROUND_COLOR)
else

View File

@@ -1,4 +1,5 @@
---@class _DBCust
---@field custId
---@field custName
---@field custType
---@field phoneNo

View File

@@ -8,13 +8,14 @@ DBUser = {}
local db = {}
local icons = {}
local poplist = {}
local rolePermission = {}
DBUser.FilterGroup = {
user = "user",
group = "group"
}
function DBUser.onGetUsers(list, groupList)
function DBUser.onGetUsers(list, groupList, permissions)
local options = ArrayList()
local values = ArrayList()
db.filters = {}
@@ -40,7 +41,7 @@ function DBUser.onGetUsers(list, groupList)
local options = ArrayList()
local values = ArrayList()
db.filters[DBUser.FilterGroup.group] = {}
for i, v in ipairs(groupList) do
for i, v in ipairs(groupList or {}) do
table.insert(db.filters[DBUser.FilterGroup.group], {name = v.name, value = v.id})
options:Add(v.name)
values:Add(v.id)
@@ -49,6 +50,11 @@ function DBUser.onGetUsers(list, groupList)
options = options,
values = values
}
--------------------------------------------
rolePermission = {}
for i, v in ipairs(permissions) do
rolePermission[v] = true
end
end
function DBUser.getFilters(group)
@@ -97,4 +103,9 @@ function DBUser.getIcon(loginNo, callback)
)
end
---public 是否有权限
function DBUser.hadPermission(key)
return rolePermission[key] or false
end
return DBUser

View File

@@ -10,12 +10,30 @@ NetProto.send = {}
---------------------------------------------------------------------------------------
local host = "app.ttf-cti.com" -- "47.111.20.34"
local port = 29004
-- local host = "192.168.1.126"
-- local port = 29000
local baseUrl = joinStr("http://", host, ":", port, "/open_api/")
-- local baseUrl = "http://47.111.20.34/home/open_api/"
local socketUrl = joinStr("ws://", host, ":", port, "/tr_socket/websocket/")
NetProto.setSeverPublish = function()
host = "app.ttf-cti.com"
port = 29004
baseUrl = joinStr("http://", host, ":", port, "/open_api/")
socketUrl = joinStr("ws://", host, ":", port, "/tr_socket/websocket/")
end
NetProto.setSeverDev = function()
host = "app.ttf-cti.com"
port = 29004
baseUrl = joinStr("http://", host, ":", port, "/open_api/")
socketUrl = joinStr("ws://", host, ":", port, "/tr_socket/websocket/")
end
NetProto.setSeverLocal = function()
host = "192.168.1.100"
port = 29004
baseUrl = joinStr("http://", host, ":", port, "/open_api/")
socketUrl = joinStr("ws://", host, ":", port, "/tr_socket/websocket/")
end
---@type Dist.SpringWebsocket.Client
local socket = Client4Stomp.self
local appid = 2020158
@@ -199,10 +217,7 @@ NetProto.getTokenForAPI = function(appsecret, callback, failedCallback, orgs)
end
NetProto.login = function(map, callback, failedCallback, orgs)
-- local map = {
-- phone = phone,
-- password = password
-- }
map.model = SystemInfo.deviceModel
NetProto.sendGet(NetProto.cmds.login, map, callback, failedCallback, orgs)
end
@@ -243,7 +258,11 @@ NetProto.cmds = {
createWfInfo = "createWfInfo", -- 创建订单
create_followUp_task = "create_followUp_task", -- 创建跟进预约
list_followUp_records = "list_followUp_records", -- 跟进记录
workFlowQuery = "workFlowQuery" -- 工单列表
workFlowQuery = "workFlowQuery", -- 工单列表
backToGH = "backToGH", -- 返回公海
delCustomerInfo = "delCustomerInfo", -- 删除客户
loadProductType = "loadProductType", -- 产品类型
pageGHQueryList = "pageGHQueryList", -- 公海列表
}
---------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------
@@ -553,8 +572,9 @@ NetProto.send.selectProductInfo = function(searchKey, page, callback, timeOutSec
content.action = NetProto.cmds.selectProductInfo
content.loginNo = NetProto.loginNo
content.groupId = NetProto.groupId
-- content.flag = 0
content.current_page = page
content.search = searchKey
content.keywords = searchKey
NetProto.sendSocket(content, callback, timeOutSec)
end
@@ -596,5 +616,38 @@ NetProto.send.workFlowQuery = function(filters, queryKey, page, callback, timeOu
content.current_page = page
NetProto.sendSocket(content, callback, timeOutSec)
end
NetProto.send.backToGH = function(ids, callback, timeOutSec)
local content = {}
content.action = NetProto.cmds.backToGH
content.groupId = NetProto.groupId
content.ids = ids
NetProto.sendSocket(content, callback, timeOutSec)
end
NetProto.send.delCustomerInfo = function(ids, callback, timeOutSec)
local content = {}
content.action = NetProto.cmds.delCustomerInfo
content.groupId = NetProto.groupId
content.ids = ids
NetProto.sendSocket(content, callback, timeOutSec)
end
NetProto.send.loadProductType = function(callback, timeOutSec)
local content = {}
content.action = NetProto.cmds.loadProductType
content.groupId = NetProto.groupId
NetProto.sendSocket(content, callback, timeOutSec)
end
NetProto.send.pageGHQueryList = function(filters, queryKey, page, callback, timeOutSec)
local content = {}
content.action = NetProto.cmds.pageGHQueryList
content.groupId = NetProto.groupId
content.filters = filters
content.keywords = queryKey
content.current_page = page
NetProto.sendSocket(content, callback, timeOutSec)
end
------------------------------------------------------
return NetProto

View File

@@ -0,0 +1,48 @@
---@class _ParamCellCustFilter
---@field name string
---@field value number
---@field selected boolean
-- xx单元
local _cell = {}
---@type Coolape.CLCellLua
local csSelf = nil
local transform = nil
---@type _ParamCellCustFilter
local mData = nil
local uiobjs = {}
-- 初始化,只调用一次
function _cell.init(csObj)
csSelf = csObj
transform = csSelf.transform
uiobjs.Label = getCC(transform, "Label", "UILabel")
uiobjs.bg = csSelf:GetComponent("UISprite")
end
-- 显示,
-- 注意c#侧不会在调用show时调用refresh
function _cell.show(go, data)
mData = data
uiobjs.Label.text = mData.name
_cell.setSelect(mData.selected)
end
function _cell.setSelect(val)
mData.selected = val
if val then
uiobjs.bg.color = ColorEx.getColor(0xff2990dc)
uiobjs.Label.color = ColorEx.getColor(0xffffffff)
else
uiobjs.bg.color = ColorEx.getColor(0xfff4f4f4)
uiobjs.Label.color = ColorEx.getColor(0xff999999)
end
end
-- 取得数据
function _cell.getData()
return mData
end
--------------------------------------------
return _cell

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: f792bcec1a2664348b80edb755526774
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,114 @@
---@class _ParamCellCustFilterGroup
---@field title
---@field key
---@field key2
---@field panel TRPCustFilter
---@field list
---@field type 1:dateTime 其它情况为选择
---@field isDateRange
---@field isNeedTime
---@field value
-- xx单元
local _cell = {}
---@type Coolape.CLCellLua
local csSelf = nil
local transform = nil
---@type _ParamCellCustFilterGroup
local mData = nil
local uiobjs = {}
local cells = {}
local firstCell
local selectedCells = {}
-- 初始化,只调用一次
function _cell.init(csObj)
csSelf = csObj
transform = csSelf.transform
uiobjs.LabelTitle = getCC(transform, "LabelTitle", "UILabel")
uiobjs.grid = getCC(transform, "Grid", "UIGrid")
uiobjs.gridPrefab = getChild(uiobjs.grid.transform, "00000").gameObject
---@type CLUIElementDate
uiobjs.InputDate = getCC(transform, "InputDate", "CLUIElementDate")
uiobjs.InputDateEl = getCC(transform, "InputDate", "CLUIElement")
end
-- 显示,
-- 注意c#侧不会在调用show时调用refresh
function _cell.show(go, data)
mData = data
uiobjs.LabelTitle.text = mData.title
if mData.type and mData.type == 1 then
SetActive(uiobjs.InputDate.gameObject, true)
SetActive(uiobjs.grid.gameObject, false)
uiobjs.InputDate.isSetTime = mData.isNeedTime or false
uiobjs.InputDate.isDateRange = mData.isDateRange or false
uiobjs.InputDateEl.value = mData.value
else
SetActive(uiobjs.InputDate.gameObject, false)
SetActive(uiobjs.grid.gameObject, true)
selectedCells = {}
cells = {}
CLUIUtl.resetList4Lua(uiobjs.grid, uiobjs.gridPrefab, mData.list, _cell.initCell)
end
end
function _cell.initCell(cell, data)
cell:init(data, _cell.onClickCell)
if data.value == -1 then
firstCell = cell
else
table.insert(cells, cell)
end
end
function _cell.onClickCell(cell, data)
data.selected = not data.selected
cell.luaTable.setSelect(data.selected)
if data.value == -1 then
-- 说明是全部
for i, v in ipairs(cells) do
v.luaTable.setSelect(data.selected)
end
else
local isAllSelected = true
for i, v in ipairs(cells) do
local d = v.luaTable.getData()
if not d.selected then
isAllSelected = false
break
end
end
if firstCell then
firstCell.luaTable.setSelect(isAllSelected)
end
end
mData.panel:refreshFilterBtnStatus()
end
-- 取得数据
function _cell.getData()
return mData
end
function _cell.uiEventDelegate(go)
if go.name == "ButtonReset" then
-- 说明是全部
for i, v in ipairs(cells) do
v.luaTable.setSelect(false)
end
if uiobjs.InputDateEl then
uiobjs.InputDateEl.value = ""
mData.value = ""
end
mData.panel:refreshFilterBtnStatus()
elseif go.name == "InputDate" then
if mData.type == 1 then
mData.value = uiobjs.InputDateEl.value
end
mData.panel:refreshFilterBtnStatus()
end
end
--------------------------------------------
return _cell

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 8ae726fabf5f04108ad1086c8ffba0d5
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -142,10 +142,9 @@ function _cell.getData()
return mData
end
function _cell.OnDisable()
if #(fieldsObjs) > 0 then
printe("动态加载的字段没有释放")
printe("动态加载的字段没有释放" .. csSelf.name)
end
end
--------------------------------------------

View File

@@ -0,0 +1,43 @@
-- xx单元
local _cell = {}
---@type Coolape.CLCellLua
local csSelf = nil
local transform = nil
---@type _DBCust
local mData = nil
local uiobjs = {}
-- 初始化,只调用一次
function _cell.init(csObj)
csSelf = csObj
transform = csSelf.transform
---@type UIPopupList
uiobjs.LabelStatus = getCC(transform, "LabelStatus", "UIPopupList")
---@type CLUIFormRoot
uiobjs.formRoot = csSelf:GetComponent("CLUIFormRoot")
uiobjs.SpriteStatus = getChild(transform, "SpriteStatus")
end
-- 显示,
-- 注意c#侧不会在调用show时调用refresh
function _cell.show(go, data)
mData = data
mData._phoneNo = MyUtl.hidePhone(mData.phoneNo)
mData.lastFollowUpTime = isNilOrEmpty(mData.upTime) and "" or mData.upTime
local optionInfor = DBCust.getFilter4Popup(DBCust.FilterGroup.dealFlagList)
uiobjs.LabelStatus:refreshItems(optionInfor.options, optionInfor.values)
uiobjs.formRoot:setValue(mData)
if tostring(mData.dealFlag) == "0" then
SetActive(uiobjs.SpriteStatus.gameObject, true)
else
SetActive(uiobjs.SpriteStatus.gameObject, false)
end
end
-- 取得数据
function _cell.getData()
return mData
end
--------------------------------------------
return _cell

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: af56f0bbcec1a44f1ae7c33a79358445
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -24,7 +24,7 @@ end
-- 注意c#侧不会在调用show时调用refresh
function _cell.show(go, data)
mData = data
mData.money = mData.prodNum * mData.salePrice
-- mData.money = mData.prodNum * mData.salePrice
mData._phoneNo = MyUtl.hidePhone(mData.phoneNo)
local optionInfor = DBOrder.getPopupList(DBOrder.PopListGroup.orderStatus)
uiobjs.LabelStatus:refreshItems(optionInfor.options, optionInfor.values)

View File

@@ -146,22 +146,26 @@ function CLLPStart.connectServer()
-- Net.self:connect(selectedServer.host, bio2number(selectedServer.port))
isLogined = true
NetProto.init(
function(success)
if success then
CLLPStart.showGuid()
else
CLUIUtl.showConfirm(
"与服务器失去联系",
false,
"重试",
CLLPStart.connectServer,
"退出",
function()
Application.Quit()
CLLPStart.selectServer(
function()
NetProto.init(
function(success)
if success then
CLLPStart.showGuid()
else
CLUIUtl.showConfirm(
"与服务器失去联系",
false,
"重试",
CLLPStart.connectServer,
"退出",
function()
Application.Quit()
end
)
end
)
end
end
)
end
)
end
@@ -187,7 +191,8 @@ function CLLPStart.doEnterGame()
NetProto.login(
{
phone = Prefs.getUserName(),
password = Prefs.getUserPsd()
password = Prefs.getUserPsd(),
model=SystemInfo.deviceModel
},
function(content, orgs)
if content.success then
@@ -255,6 +260,33 @@ CLLPStart.showGuid = function()
end
end
CLLPStart.selectServer = function(callback)
local userName = Prefs.getUserName()
if isNilOrEmpty(userName) then
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
getPanelAsy("PanelSelectServer", onLoadedPanelTT, {callback = callback})
else
Utl.doCallback(callback)
end
end,
function()
Utl.doCallback(callback)
end,
nil,
true,
1
)
end
CLLPStart.hideSplash = function()
local p2 = CLPanelManager.getPanel("PanelSplash")
if (p2 ~= nil) then

View File

@@ -157,6 +157,7 @@ function CSPTasks.setEventDelegate()
getPanelAsy("PanelFollowList", onLoadedPanelTT)
end,
ButtonCustOcean = function()
getPanelAsy("PanelOceanList", onLoadedPanelTT)
end,
ButtonOrder = function()
getPanelAsy("PanelOrderList", onLoadedPanelTT)

View File

@@ -41,13 +41,13 @@ function TRPAbout:initFiledsAttr()
attr.donotJoinKey = true
table.insert(self.baseFiledsAttr, attr)
attr = {}
attr.attrName = "发布评价"
attr.id = "assess"
attr.attrType = DBCust.FieldType.text
attr.ifMust = 0
attr.donotJoinKey = true
table.insert(self.baseFiledsAttr, attr)
-- attr = {}
-- attr.attrName = "发布评价"
-- attr.id = "assess"
-- attr.attrType = DBCust.FieldType.text
-- attr.ifMust = 0
-- attr.donotJoinKey = true
-- table.insert(self.baseFiledsAttr, attr)
end
-- 设置数据
@@ -80,13 +80,71 @@ end
function TRPAbout:onClickField(el)
if el.jsonKey == "upgrade" then
-- 更新
self:upgrade()
elseif el.jsonKey == "serviceAgreement" then
-- 显示协议
local path =
joinStr(
CLPathCfg.self.basePath,
"/",
CLPathCfg.upgradeRes,
"/other/txt/",
CLPathCfg.self.platform,
"/serviceProto",
".unity3d"
)
CLVerManager.self:getNewestRes(
path,
CLAssetType.assetBundle,
function(path, content, orgs)
if content then
local msg = content.mainAsset and content.mainAsset.text or ""
content:Unload(false)
getPanelAsy(
"PanelSysMsgDetail",
onLoadedPanelTT,
{PanelTitle = "服务协议", TITLE = "服务协议", CONTENT = msg}
)
end
end,
true,
nil
)
elseif el.jsonKey == "assess" then
-- 评价(这个做起来麻烦)
-- 评价(这个做起来麻烦)
end
end
function TRPAbout:upgrade()
showHotWheel()
local oldVer = __version__
local onGetVer = function(content, orgs)
hideHotWheel()
local map = JSON.DecodeMap(content)
local newVer = MapEx.getString(map, "ver")
if (tonumber(newVer) > tonumber(oldVer)) then
local doUpgradeApp = function()
Application.OpenURL(MapEx.getString(map, "url"))
end
if MapEx.getBool(map, "force") then
CLUIUtl.showConfirm(LGet("MsgHadNewVerApp"), true, "更新", doUpgradeApp, "", nil)
else
CLUIUtl.showConfirm(LGet("MsgHadNewVerApp"), false, "更新", doUpgradeApp, "忽略", nil)
end
else
MyUtl.toastS("当前已经是最新版本 V" .. newVer)
end
end
local onGetVerError = function(msg, orgs)
hideHotWheel()
MyUtl.toastW("更新检查失败")
end
local chlCode = getChlCode()
local url = Utl.urlAddTimes(joinStr(CLVerManager.self.baseUrl, "/appVer.", chlCode, ".json"))
WWWEx.get(url, CLAssetType.text, onGetVer, onGetVerError, nil, true, 1)
end
function TRPAbout:onSelectField(go)
end
@@ -98,7 +156,6 @@ end
-- 刷新
function TRPAbout:refresh()
uiobjs.TableLua.luaTable.release()
end
-- 关闭页面

View File

@@ -74,11 +74,15 @@ function TRPComFilter:refreshFilterBtnStatus()
end
function TRPComFilter:hadFilterVal()
for i,v in ipairs(self.list) do
for j, f in ipairs(v.list) do
if f.selected then
return true
for i, v in ipairs(self.list) do
if v.list then
for j, f in ipairs(v.list) do
if f.selected then
return true
end
end
elseif not isNilOrEmpty(v.value) then
return true
end
end
return false
@@ -104,9 +108,14 @@ end
function TRPComFilter:reset()
uiobjs.InputSeachKey.value = ""
for i,v in ipairs(self.list) do
for j, f in ipairs(v.list) do
f.selected = false
---@type _ParamCellCustFilterGroup
for i, v in ipairs(self.list) do
if v.list then
for j, f in ipairs(v.list) do
f.selected = false
end
else
v.value = ""
end
end
CLUIUtl.resetList4Lua(uiobjs.Table, uiobjs.prefab, self.list, self:wrapFunc(self.initCell))

View File

@@ -30,7 +30,7 @@ function TRPConnect.show()
local phone = Prefs.getUserName()
local currGroup = Prefs.getCurrGroup(Prefs.getUserName())
companyInfro = json.decode(currGroup)
DBUser.onGetUsers(companyInfro.loginNoList, companyInfro.groupInfoList) -- 缓存工号相关信息
DBUser.onGetUsers(companyInfro.loginNoList, companyInfro.groupInfoList, companyInfro.rolePermissions) -- 缓存工号相关信息
NetProto.socketInit(companyInfro.company_id, companyInfro.login_no, companyInfro.group_id)
end
@@ -88,6 +88,7 @@ function TRPConnect.getDataFromServer()
NetProto.send.booking_query()
NetProto.send.replenish_query()
NetProto.send.load_wfTicket_Settings()
NetProto.send.loadProductType()
end
-- 处理ui上的事件例如点击等

View File

@@ -97,7 +97,7 @@ function TRPCustDetail:prepareMoreData()
attr.donotJoinKey = true
table.insert(self.moreProcList, attr)
--------------------------------------------
self.sysFields = {}
---@type _ParamFieldAttr
local attr = {}
@@ -359,21 +359,20 @@ function TRPCustDetail:showOrders()
)
else
showHotWheel()
-- //TODO:
MyUtl.toastW("TODO:取何取得单个客户的订单???")
NetProto.send.query_cust_calllog(self.mdata.phoneNo, nil, 1)
NetProto.send.workFlowQuery({custId = self.mdata.custId}, "", 1)
uiobjs.OrderRoot:setList({}, self:wrapFunc(self.initOrderCell))
end
uiobjs.Table:Reposition()
uiobjs.scrollView.disableDragIfFits = false
uiobjs.scrollView:ResetPosition()
self:reposition()
end
function TRPCustDetail:initOrderCell(cell, data)
cell:init(data, nil)
cell:init(data, self:wrapFunc(self.onClickOrderCell))
end
function TRPCustDetail:onClickOrderCell(cell, data)
getPanelAsy("PanelOrderDetail", onLoadedPanelTT, data)
end
function TRPCustDetail:onOrderHeadList(head)
printw("到最顶端了")
end
@@ -383,7 +382,7 @@ function TRPCustDetail:onOrderEndList(tail)
if self.orders and self.orders.meta.current_page < self.orders.meta.total_pages then
showHotWheel()
-- //TODO:取得下一页
NetProto.send.query_cust_calllog(self.mdata.phoneNo, nil, self.orders.meta.current_page + 1)
NetProto.send.workFlowQuery({custId = self.mdata.custId}, "", self.orders.meta.current_page + 1)
else
uiobjs.ButtonEndListOrder.localPosition = tail.transform.localPosition + Vector3.up * -270
SetActive(uiobjs.ButtonEndListOrder.gameObject, true)
@@ -434,7 +433,7 @@ function TRPCustDetail:onClickMoreProc(el)
elseif el.jsonKey == "smsList" then
-- 短信记录
elseif el.jsonKey == "opList" then
-- 操作记录
-- 操作记录
end
end
@@ -449,6 +448,9 @@ function TRPCustDetail:release()
if uiobjs.MoreRoot.luaTable then
uiobjs.MoreRoot.luaTable.release()
end
if uiobjs.SysRoot.luaTable then
uiobjs.SysRoot.luaTable.release()
end
self.hasSetMoreProc = false
end
@@ -481,11 +483,39 @@ function TRPCustDetail:procNetwork(cmd, succ, msg, paras)
uiobjs.Records:appendList(result.data)
end
end
elseif cmd == NetProto.cmds.workFlowQuery then
local result = paras.result
if self.orders == nil then
self.orders = result
else
if self.orders.meta.current_page < result.meta.current_page then
self.orders.meta = result.meta
for i, v in ipairs(result.data) do
table.insert(self.orders.data, v)
end
end
end
hideHotWheel()
if self.orders and uiobjs.OrderRoot.gameObject.activeInHierarchy then
if self.orders.meta.current_page == 1 then
self:showOrders()
else
uiobjs.OrderRoot:appendList(result.data)
end
end
elseif cmd == NetProto.cmds.update_customer then
if self.currToggle == 1 then
self:showDetail()
uiobjs.Head:setValue(self.mdata)
end
elseif cmd == NetProto.cmds.delCustomerInfo or cmd == NetProto.cmds.backToGH then
hideTopPanel(self.csSelf)
elseif cmd == NetProto.cmds.createWfInfo then
self.orders = nil
if self.currToggle == 3 then
self:showOrders()
end
end
end
end

View File

@@ -97,10 +97,15 @@ function TRPCustList:show()
end
function TRPCustList:showList(list)
list = list or {}
SetActive(uiobjs.ButtonHeadList.gameObject, false)
SetActive(uiobjs.ButtonEndList.gameObject, false)
if #list > 0 then
SetActive(uiobjs.ButtonEndList.gameObject, false)
else
SetActive(uiobjs.ButtonEndList.gameObject, true)
end
uiobjs.Grid:setList(
list or {},
list,
self:wrapFunc(self.initCell),
self:wrapFunc(self.onHeadList),
self:wrapFunc(self.onEndList)
@@ -202,6 +207,8 @@ function TRPCustList:procNetwork(cmd, succ, msg, paras)
uiobjs.Grid:refreshContentOnly()
elseif cmd == NetProto.cmds.save_customer then
self:refreshList()
elseif cmd == NetProto.cmds.delCustomerInfo or cmd == NetProto.cmds.backToGH then
self:refreshList()
end
end
end

View File

@@ -7,6 +7,7 @@ local uiobjs = {}
-- 初始化,只会调用一次
function TRPFollowList:init(csObj)
TRPFollowList.super.init(self, csObj)
self:initFilters()
self:setEventDelegate()
MyUtl.setContentView(getChild(self.transform, "PanelContent"), 132 + 132 + 40, 0)
uiobjs.InputSeachKey = getCC(self.transform, "Top/InputSeachKey", "UIInput")
@@ -26,6 +27,61 @@ function TRPFollowList:init(csObj)
uiobjs.ButtonHeadList = getChild(uiobjs.Grid.transform, "ButtonHeadList")
end
function TRPFollowList:initFilters()
self.filters = {}
---@type _ParamCellCustFilterGroup
local d = {}
d = {}
d.title = "跟进时间"
d.key = "dateRange"
d.key2 = "dateRange"
d.type = 1
d.isDateRange = true
d.isNeedTime = true
table.insert(self.filters, d)
d = {}
d.title = "跟进类型"
d.key = DBCust.FilterGroup.followUpTypeList
d.key2 = "followTypeUp"
d.list = DBCust.getFilter(DBCust.FilterGroup.followUpTypeList)
if d.list and #(d.list) > 0 then
-- table.insert(d.list, 1, {name = "全部", value = -1})
table.insert(self.filters, d)
end
d = {}
d.title = "跟进类型"
d.key = DBCust.FilterGroup.followUpTypeList
d.key2 = "followTypeUp"
d.list = DBCust.getFilter(DBCust.FilterGroup.followUpTypeList)
if d.list and #(d.list) > 0 then
-- table.insert(d.list, 1, {name = "全部", value = -1})
table.insert(self.filters, d)
end
d = {}
d.title = "商机"
d.key = DBCust.FilterGroup.opportunityList
d.key2 = "opportunity"
d.list = DBCust.getFilter(DBCust.FilterGroup.opportunityList)
if d.list and #(d.list) > 0 then
-- table.insert(d.list, 1, {name = "全部", value = -1})
table.insert(self.filters, d)
end
d = {}
d.title = "跟进人员"
d.key = "loginNos"
d.key2 = "loginNos"
d.list = DBUser.getFilters(DBUser.FilterGroup.user)
if d.list and #(d.list) > 0 then
-- table.insert(d.list, 1, {name = "全部", value = -1})
table.insert(self.filters, d)
end
end
-- 设置数据
---@param paras _ParamTRPFollowList
function TRPFollowList:setData(paras)
@@ -42,8 +98,13 @@ function TRPFollowList:show()
end
function TRPFollowList:showList(list)
list = list or {}
SetActive(uiobjs.ButtonHeadList.gameObject, false)
SetActive(uiobjs.ButtonEndList.gameObject, false)
if #list > 0 then
SetActive(uiobjs.ButtonEndList.gameObject, false)
else
SetActive(uiobjs.ButtonEndList.gameObject, true)
end
uiobjs.Grid:setList(
list or {},
self:wrapFunc(self.initCell),
@@ -114,10 +175,14 @@ end
function TRPFollowList:hadFilterVal()
for i, v in ipairs(self.filters or {}) do
for j, f in ipairs(v.list) do
if f.selected then
return true
if v.list then
for j, f in ipairs(v.list) do
if f.selected then
return true
end
end
elseif not isNilOrEmpty(v.value) then
return true
end
end
if self.startTime then
@@ -154,7 +219,7 @@ function TRPFollowList:setEventDelegate()
self.EventDelegate = {
ButtonFilter = function()
getPanelAsy(
"PanelFollowFilter",
"PanelComFilter",
onLoadedPanelTT,
{
callback = self:wrapFunc(self.onSetFilter),
@@ -178,21 +243,24 @@ function TRPFollowList:getFilterStr()
local ret = {}
for i, g in ipairs(self.filters) do
local list = {}
for j, f in ipairs(g.list) do
if f.selected and f.value ~= -1 then
if g.key == DBCust.FilterGroup.opportunityList or g.key == DBCust.FilterGroup.followUpTypeList then
table.insert(list, f.name)
else
table.insert(list, f.value)
if g.list then
for j, f in ipairs(g.list) do
if f.selected and f.value ~= -1 then
if g.key == DBCust.FilterGroup.opportunityList or g.key == DBCust.FilterGroup.followUpTypeList then
table.insert(list, f.name)
else
table.insert(list, f.value)
end
end
end
ret[g.key2] = table.concat(list, ",")
elseif g.key == "dateRange" then
if not isNilOrEmpty(g.value) then
local strs = strSplit(g.value, "~")
ret.startTime = strs[1]
ret.endTime = strs[2]
end
end
ret[g.key2] = table.concat(list, ",")
end
if self.startTime then
ret.startTime = self.startTime
ret.endTime = self.endTime
end
return ret
end

View File

@@ -1,5 +1,4 @@

---@type IDBasePanel
---@type IDBasePanel
local TRBasePanel = require("ui.panel.TRBasePanel")
---@class TRPMoreProc4Cust:TRBasePanel 邮件列表
local TRPMoreProc4Cust = class("TRPMoreProc4Cust", TRBasePanel)
@@ -15,6 +14,7 @@ end
-- 设置数据
---@param paras _ParamTRPMoreProc4Cust
function TRPMoreProc4Cust:setData(paras)
---@type _DBCust
self.mdata = paras
end
@@ -33,10 +33,10 @@ end
-- 网络请求的回调cmd指命succ成功失败msg消息paras服务器下行数据
function TRPMoreProc4Cust:procNetwork(cmd, succ, msg, paras)
if (succ == NetSuccess) then
--[[
if cmd == xx then
if cmd == NetProto.cmds.delCustomerInfo or cmd == NetProto.cmds.backToGH then
hideHotWheel()
hideTopPanel(self.csSelf)
end
]]
end
end
@@ -51,6 +51,14 @@ function TRPMoreProc4Cust:setEventDelegate()
ButtonSendSM = function()
end,
ButtonMovetoOcean = function()
MyUtl.confirm(
"确定要将客户移到公海?",
function()
showHotWheel()
NetProto.send.backToGH(self.mdata.custId)
end,
"确认"
)
end,
ButtonGetCust = function()
end,
@@ -62,7 +70,15 @@ function TRPMoreProc4Cust:setEventDelegate()
ButtonCheckIn = function()
end,
ButtonDelCust = function()
end,
MyUtl.confirm(
"确定要删除客户?",
function()
showHotWheel()
NetProto.send.delCustomerInfo(self.mdata.custId)
end,
"确认删除"
)
end
}
end
-- 处理ui上的事件例如点击等

View File

@@ -57,6 +57,7 @@ function TRPNewFollow:initFiledsAttr()
attr.id = ""
attr.attrType = DBCust.FieldType.dateTime
attr.ifMust = 1
attr.ifTime = 1
attr.donotJoinKey = true
table.insert(self.baseFiledsAttr, attr)
@@ -149,9 +150,12 @@ function TRPNewFollow:onPopupFieldValChg(go)
---@type CLUIElement
local el = go:GetComponent("CLUIElement")
if el.jsonKey == "dealFlag" then
if uiobjs.followUpContent and isNilOrEmpty(uiobjs.followUpContent.value) then
if uiobjs.followUpContent then
local popList = go:GetComponent("UIPopupList")
uiobjs.followUpContent.value = popList.selectedItem
if isNilOrEmpty(uiobjs.followUpContent.value) or self.oldselectedItem == uiobjs.followUpContent.value then
uiobjs.followUpContent.value = popList.selectedItem
self.oldselectedItem = popList.selectedItem
end
end
end
end
@@ -167,6 +171,7 @@ end
-- 关闭页面
function TRPNewFollow:hide()
self.oldselectedItem = nil
if uiobjs.DetailRoot.luaTable then
uiobjs.DetailRoot.luaTable.release()
end

View File

@@ -88,6 +88,7 @@ function TRPNewFollowSimple:showBaseFields()
local param = {}
param.data = self.mdata or {}
param.onFinish = self:wrapFunc(self.setExtendFieldsMode)
param.onLoadOneField = self:wrapFunc(self.onLoadOneField)
param.fields = {}
---@type _ParamCellExtendFiled
local filedInfor
@@ -111,9 +112,12 @@ function TRPNewFollowSimple:onPopupFieldValChg(go)
---@type CLUIElement
local el = go:GetComponent("CLUIElement")
if el.jsonKey == "dealFlag" then
if uiobjs.followUpContent and isNilOrEmpty(uiobjs.followUpContent.value) then
if uiobjs.followUpContent then
local popList = go:GetComponent("UIPopupList")
uiobjs.followUpContent.value = popList.selectedItem
if isNilOrEmpty(uiobjs.followUpContent.value) or self.oldselectedItem == uiobjs.followUpContent.value then
uiobjs.followUpContent.value = popList.selectedItem
self.oldselectedItem = popList.selectedItem
end
end
end
end
@@ -123,14 +127,17 @@ function TRPNewFollowSimple:reposition()
uiobjs.Table.repositionNow = true
end
function TRPNewFollowSimple:onLoadOneField(cell)
local el = cell:GetComponent("CLUIElement")
if el and el.jsonKey == "followUpContent" then
uiobjs.followUpContent = el
end
end
function TRPNewFollowSimple:setExtendFieldsMode(root)
local elements = root:GetComponentsInChildren(typeof(CLUIElement), true)
for i = 0, elements.Length - 1 do
self:setElementMode(elements[i])
if elements[i].jsonKey == "followUpContent" then
---@type CLUIElement
uiobjs.followUpContent = elements[i]
end
end
self:reposition()
end
@@ -181,6 +188,7 @@ end
-- 关闭页面
function TRPNewFollowSimple:hide()
self.oldselectedItem = nil
if uiobjs.DetailRoot.luaTable then
uiobjs.DetailRoot.luaTable.release()
end

View File

@@ -538,6 +538,11 @@ function TRPNewOrder:setEventDelegate()
order.attrJson = attrJson
end
if uiobjs.StepFormRoot.gameObject.activeInHierarchy then
err = joinStr(err, uiobjs.StepFormRoot:checkValid())
if not isNilOrEmpty(err) then
MyUtl.toastW(err)
return
end
order = uiobjs.StepFormRoot:getValue(order, true)
end
local templateInfor = DBOrder.getTemplateInfor(order.templetId)

View File

@@ -0,0 +1,287 @@
---@type IDBasePanel
local TRBasePanel = require("ui.panel.TRBasePanel")
---@class TRPOceanList:TRBasePanel
local TRPOceanList = class("TRPOceanList", TRBasePanel)
local uiobjs = {}
-- 初始化,只会调用一次
function TRPOceanList:init(csObj)
TRPOceanList.super.init(self, csObj)
self:setEventDelegate()
self:initFilters()
MyUtl.setContentView(getChild(self.transform, "PanelContent"), 132 + 132 + 40, 0)
uiobjs.InputSeachKey = getCC(self.transform, "Top/InputSeachKey", "UIInput")
uiobjs.ButtonFilterSp = getCC(self.transform, "Top/ButtonFilter", "UISprite")
uiobjs.ButtonFilterLb = getCC(uiobjs.ButtonFilterSp.transform, "Label", "UILabel")
---@type CLUIScrollViewWithEvent
uiobjs.scrollView = getCC(self.transform, "PanelContent", "CLUIScrollViewWithEvent")
uiobjs.scrollView:init(
self:wrapFunc(self.onShowRefreshFlg),
self:wrapFunc(self.onhideRefreshFlg),
self:wrapFunc(self.refreshList)
)
---@type Coolape.CLUILoopGrid
uiobjs.Grid = getCC(uiobjs.scrollView.transform, "Grid", "CLUILoopGrid")
uiobjs.ButtonEndList = getChild(uiobjs.Grid.transform, "ButtonEndList")
uiobjs.ButtonEndListLb = getCC(uiobjs.ButtonEndList, "Label", "UILabel")
uiobjs.ButtonHeadList = getChild(uiobjs.Grid.transform, "ButtonHeadList")
end
function TRPOceanList:initFilters()
self.filters = {}
---@type _ParamCellCustFilterGroup
local d = {}
d.title = "创建时间"
d.key = "createTime"
d.key2 = "createTime"
d.type = 1
d.isDateRange = true
d.isNeedTime = true
table.insert(self.filters, d)
d = {}
d.title = "更新时间"
d.key = "updateTime"
d.key2 = "updateTime"
d.type = 1
d.isDateRange = true
d.isNeedTime = true
table.insert(self.filters, d)
d = {}
d.title = "任务名称"
d.key = DBCust.FilterGroup.taskList
d.key2 = "taskId"
d.list = DBCust.getFilter(DBCust.FilterGroup.taskList)
if #(d.list) > 0 then
-- table.insert(d.list, 1, {name = "全部", value = -1})
table.insert(self.filters, d)
end
d = {}
d.title = "跟进阶段"
d.key = DBCust.FilterGroup.dealFlagList
d.key2 = "payStatus"
d.list = DBCust.getFilter(DBCust.FilterGroup.dealFlagList)
if #(d.list) > 0 then
-- table.insert(d.list, 1, {name = "全部", value = -1})
table.insert(self.filters, d)
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)
self.mdata = paras
end
-- 显示在c#中。show为调用refreshshow和refresh的区别在于当页面已经显示了的情况当页面再次出现在最上层时只会调用refresh
function TRPOceanList:show()
uiobjs.InputSeachKey.value = ""
self:resetFilters()
self:refreshFilterBtnStatus()
self:showList({})
showHotWheel()
NetProto.send.pageGHQueryList(self.filterValue, "", 1)
end
function TRPOceanList:showList(list)
list = list or {}
SetActive(uiobjs.ButtonHeadList.gameObject, false)
if #list > 0 then
SetActive(uiobjs.ButtonEndList.gameObject, false)
else
SetActive(uiobjs.ButtonEndList.gameObject, true)
end
uiobjs.Grid:setList(
list or {},
self:wrapFunc(self.initCell),
self:wrapFunc(self.onHeadList),
self:wrapFunc(self.onEndList)
)
uiobjs.scrollView:ResetPosition()
end
function TRPOceanList:appList(list)
SetActive(uiobjs.ButtonEndList.gameObject, false)
uiobjs.Grid:appendList(list)
end
function TRPOceanList:onShowRefreshFlg()
-- printe("TRPOceanList:onShowRefreshFlg")
uiobjs.ButtonHeadList.transform.localPosition = Vector3(0, 222, 0)
SetActive(uiobjs.ButtonHeadList.gameObject, true)
end
function TRPOceanList:onhideRefreshFlg()
-- printe("TRPOceanList:onhideRefreshFlg")
SetActive(uiobjs.ButtonHeadList.gameObject, false)
end
function TRPOceanList:refreshList()
local queryKey = uiobjs.InputSeachKey.value
showHotWheel()
NetProto.send.pageGHQueryList(self.filterValue, queryKey, 1)
end
function TRPOceanList:onHeadList(head)
printw("到最顶端了")
-- uiobjs.ButtonHeadList.transform.localPosition = Vector3(0, 250, 0)
-- SetActive(uiobjs.ButtonHeadList.gameObject, true)
end
function TRPOceanList:onEndList(tail)
printw("到最后了==" .. tail.name)
if self.pageInfo and self.pageInfo.current_page < self.pageInfo.total_pages then
local queryKey = uiobjs.InputSeachKey.value
showHotWheel()
-- 取得下一页
NetProto.send.pageGHQueryList(self.filterValue, queryKey, self.pageInfo.current_page + 1)
else
uiobjs.ButtonEndList.localPosition = tail.transform.localPosition + Vector3.up * -235
SetActive(uiobjs.ButtonEndList.gameObject, true)
end
end
function TRPOceanList:initCell(cell, data)
cell:init(data, self:wrapFunc(self.onClickCell))
end
function TRPOceanList:onClickCell(cell, data)
getPanelAsy("PanelOrderDetail", onLoadedPanelTT, data)
end
function TRPOceanList:refreshFilterBtnStatus()
if self:hadFilterVal() then
uiobjs.ButtonFilterLb.color = ColorEx.getColor(0xff2990dc)
uiobjs.ButtonFilterSp.color = ColorEx.getColor(0xff2990dc)
uiobjs.ButtonFilterSp.spriteName = "cust_funnel"
else
uiobjs.ButtonFilterLb.color = ColorEx.getColor(0xff999999)
uiobjs.ButtonFilterSp.color = ColorEx.getColor(0xff999999)
uiobjs.ButtonFilterSp.spriteName = "cust_screen"
end
end
function TRPOceanList:hadFilterVal()
for i, v in ipairs(self.filters or {}) do
if v.list then
for j, f in ipairs(v.list) do
if f.selected then
return true
end
end
elseif not isNilOrEmpty(v.value) then
return true
end
end
return false
end
-- 刷新
function TRPOceanList:refresh()
end
-- 关闭页面
function TRPOceanList:hide()
self.filterValue = nil
end
-- 网络请求的回调cmd指命succ成功失败msg消息paras服务器下行数据
function TRPOceanList:procNetwork(cmd, succ, msg, paras)
if (succ == NetSuccess) then
if cmd == NetProto.cmds.pageGHQueryList then
local result = paras.result or {}
self.pageInfo = result.meta
if self.pageInfo and self.pageInfo.current_page > 1 then
self:appList(result.data)
else
self:showList(result.data)
end
hideHotWheel()
elseif cmd == NetProto.cmds.update_customer then
uiobjs.Grid:refreshContentOnly()
elseif cmd == NetProto.cmds.save_customer then
self:refreshList()
end
end
end
function TRPOceanList:setEventDelegate()
self.EventDelegate = {
ButtonFilter = function()
getPanelAsy(
"PanelComFilter",
onLoadedPanelTT,
{
title = "订单筛选",
callback = self:wrapFunc(self.onSetFilter),
queryKey = uiobjs.InputSeachKey.value,
defautFilter = self.filters
}
)
end,
InputSeachKey = function()
local queryKey = uiobjs.InputSeachKey.value
NetProto.send.pageGHQueryList(self.filterValue, queryKey, 1)
end
}
end
function TRPOceanList:getFilterStr()
if not self.filters then
return ""
end
local ret = {}
for i, g in ipairs(self.filters) do
if g.list then
local list = {}
for j, f in ipairs(g.list) do
if f.selected and f.value ~= -1 then
table.insert(list, f.value)
end
end
ret[g.key2] = table.concat(list, ",")
elseif g.key == "createTime" then
--//TODO:
elseif g.key == "updateTime" then
--//TODO:
end
end
return ret
end
function TRPOceanList:onSetFilter(filters, queryKey)
local oldqueryKey = uiobjs.InputSeachKey.value
uiobjs.InputSeachKey.value = queryKey
self.filters = filters
self:refreshFilterBtnStatus()
local queryKey = uiobjs.InputSeachKey.value
queryKey = trim(queryKey)
showHotWheel()
self.filterValue = self:getFilterStr()
if oldqueryKey == queryKey then
NetProto.send.pageGHQueryList(self.filterValue, queryKey, 1)
else
-- 会触发input的onChange事件
end
end
-- 处理ui上的事件例如点击等
function TRPOceanList:uiEventDelegate(go)
local func = self.EventDelegate[go.name]
if func then
func()
end
end
-- 当顶层页面发生变化时回调
function TRPOceanList:onTopPanelChange(topPanel)
end
--------------------------------------------
return TRPOceanList

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 6b28699b6e85042abbe39aeb10d1bcf5
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -103,8 +103,13 @@ function TRPOrderList:show()
end
function TRPOrderList:showList(list)
list = list or {}
SetActive(uiobjs.ButtonHeadList.gameObject, false)
SetActive(uiobjs.ButtonEndList.gameObject, false)
if #list > 0 then
SetActive(uiobjs.ButtonEndList.gameObject, false)
else
SetActive(uiobjs.ButtonEndList.gameObject, true)
end
uiobjs.Grid:setList(
list or {},
self:wrapFunc(self.initCell),

View File

@@ -44,7 +44,11 @@ function TRPProductList:showList(products)
uiobjs.Grid:setList(list, self:wrapFunc(self.initCell), nil, self:wrapFunc(self.onEndList))
uiobjs.scrollView:ResetPosition()
end
function TRPProductList:appList(list)
function TRPProductList:appList(products)
local list = {}
for i, v in ipairs(products or {}) do
table.insert(list, {data = v, isSelected = false})
end
SetActive(uiobjs.ButtonEndList.gameObject, false)
uiobjs.Grid:appendList(list)
end

View File

@@ -0,0 +1,74 @@
---@type IDBasePanel
local TRBasePanel = require("ui.panel.TRBasePanel")
---@class TRPSelectServer:TRBasePanel 邮件列表
local TRPSelectServer = class("TRPSelectServer", TRBasePanel)
local uiobjs = {}
-- 初始化,只会调用一次
function TRPSelectServer:init(csObj)
TRPSelectServer.super.init(self, csObj)
self:setEventDelegate()
end
-- 设置数据
---@param paras _ParamTRPSelectServer
function TRPSelectServer:setData(paras)
self.mdata = paras
end
-- 显示在c#中。show为调用refreshshow和refresh的区别在于当页面已经显示了的情况当页面再次出现在最上层时只会调用refresh
function TRPSelectServer:show()
end
-- 刷新
function TRPSelectServer:refresh()
end
-- 关闭页面
function TRPSelectServer:hide()
end
-- 网络请求的回调cmd指命succ成功失败msg消息paras服务器下行数据
function TRPSelectServer:procNetwork(cmd, succ, msg, paras)
if (succ == NetSuccess) then
--[[
if cmd == xx then
end
]]
end
end
function TRPSelectServer:setEventDelegate()
self.EventDelegate = {
ButtonServer = function()
hideTopPanel(self.csSelf)
NetProto.setSeverPublish()
Utl.doCallback(self.mdata.callback)
end,
ButtonServerDev = function()
hideTopPanel(self.csSelf)
NetProto.setSeverDev()
Utl.doCallback(self.mdata.callback)
end,
ButtonServerLoc = function()
hideTopPanel(self.csSelf)
NetProto.setSeverLocal()
Utl.doCallback(self.mdata.callback)
end
}
end
-- 处理ui上的事件例如点击等
function TRPSelectServer:uiEventDelegate(go)
local func = self.EventDelegate[go.name]
if func then
func()
end
end
-- 当顶层页面发生变化时回调
function TRPSelectServer:onTopPanelChange(topPanel)
end
--------------------------------------------
return TRPSelectServer

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 382b52baaa31844a1b2c2fda33397c5e
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -1,6 +1,6 @@
---@type IDBasePanel
local TRBasePanel = require("ui.panel.TRBasePanel")
---@class TRPSysMsgDetail:TRBasePanel 邮件列表
---@class TRPSysMsgDetail:TRBasePanel
local TRPSysMsgDetail = class("TRPSysMsgDetail", TRBasePanel)
local uiobjs = {}
@@ -25,10 +25,22 @@ function TRPSysMsgDetail:setData(paras)
self.mdata = paras
end
---public 当有通用背板显示时的回调
---@param cs Coolape.CLPanelLua
function TRPSysMsgDetail:onShowFrame(cs)
if cs.frameObj then
---@type _BGFrame1Param
local d = {}
-- d.title = LGet(cs.titleKeyName)
d.title = self.mdata.PanelTitle or "公告详情"
d.panel = cs
cs.frameObj:init(d)
end
end
-- 显示在c#中。show为调用refreshshow和refresh的区别在于当页面已经显示了的情况当页面再次出现在最上层时只会调用refresh
function TRPSysMsgDetail:show()
self.uiobjs.LabelContent.text = joinStr(" ", self.mdata.CONTENT)
self.uiobjs.LabelTime.text = DateEx.formatByMs(tonumber(self.mdata.CREATETIME) * 1000)
self.uiobjs.LabelTime.text = self.mdata.CREATETIME and DateEx.formatByMs(tonumber(self.mdata.CREATETIME) * 1000) or ""
self.uiobjs.LabelTitle.text = self.mdata.TITLE
self.uiobjs.scrollView:ResetPosition()
end