modify
This commit is contained in:
@@ -35,7 +35,7 @@ function _cell.show(go, data)
|
||||
SetActive(uiobjs.DownloadProgress.gameObject, false)
|
||||
|
||||
--//TODO:权限判断,如果有权限的可以考虑直接显示图片
|
||||
if DBTextures.hadDownloaded(mData.name) then
|
||||
if DBAttachment.hadDownloaded(mData.name) then
|
||||
SetActive(uiobjs.ButtonDownload, false)
|
||||
SetActive(uiobjs.SpriteRight, true)
|
||||
else
|
||||
@@ -57,7 +57,7 @@ function _cell.download()
|
||||
isDownLoading = true
|
||||
SetActive(uiobjs.ButtonDownload, false)
|
||||
www =
|
||||
DBTextures.download(
|
||||
DBAttachment.download(
|
||||
mData.name,
|
||||
mData.url,
|
||||
function(content, localPath)
|
||||
|
||||
@@ -38,7 +38,7 @@ function _cell.show(go, data)
|
||||
if uiobjs.texture.mainTexture and uiobjs.texture.mainTexture.name == mData.path then
|
||||
else
|
||||
_cell.release()
|
||||
DBTextures.getByUrl(url, _cell.onGetTextue, mData.path)
|
||||
DBAttachment.getByUrl(url, _cell.onGetTextue, mData.path)
|
||||
end
|
||||
|
||||
SetActive(uiobjs.success.gameObject, false)
|
||||
@@ -48,7 +48,7 @@ end
|
||||
function _cell.upload()
|
||||
SetActive(uiobjs.Failed.gameObject, false)
|
||||
www =
|
||||
DBTextures.upload(
|
||||
DBAttachment.upload(
|
||||
mData.path,
|
||||
DBOrder.getUploadPath(),
|
||||
function(content)
|
||||
@@ -107,7 +107,7 @@ end
|
||||
function _cell.uiEventDelegate(go)
|
||||
if go.name == "ButtonDel" then
|
||||
csSelf:cancelInvoke4Lua(_cell.refreshProgress)
|
||||
DBTextures.cancelUpload(mData.path, DBOrder.getUploadPath())
|
||||
DBAttachment.cancelUpload(mData.path, DBOrder.getUploadPath())
|
||||
www = nil
|
||||
Utl.doCallback(mData.onDelete, mData)
|
||||
elseif go.name == "ButtonReload" then
|
||||
|
||||
@@ -21,6 +21,8 @@ end
|
||||
-- 注意,c#侧不会在调用show时,调用refresh
|
||||
function _cell.show(go, data)
|
||||
mData = data
|
||||
mData._callerno = MyUtl.hidePhone(mData.callerno)
|
||||
mData._destno = MyUtl.hidePhone(mData.destno)
|
||||
uiobjs.formRoot:setValue(mData)
|
||||
if not isNilOrEmpty(mData.recordfile) then
|
||||
SetActive(uiobjs.ButtonPlayVoice.gameObject, true)
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
-- xx单元
|
||||
local _cell = {}
|
||||
---@type Coolape.CLCellLua
|
||||
local csSelf = nil
|
||||
local transform = nil
|
||||
local mData = nil
|
||||
local uiobjs = {}
|
||||
|
||||
-- 初始化,只调用一次
|
||||
function _cell.init(csObj)
|
||||
csSelf = csObj
|
||||
transform = csSelf.transform
|
||||
--[[
|
||||
上的组件:getChild(transform, "offset", "Progress BarHong"):GetComponent("UISlider");
|
||||
--]]
|
||||
end
|
||||
|
||||
-- 显示,
|
||||
-- 注意,c#侧不会在调用show时,调用refresh
|
||||
function _cell.show(go, data)
|
||||
mData = data
|
||||
--[[
|
||||
TODO:
|
||||
--]]
|
||||
end
|
||||
|
||||
-- 取得数据
|
||||
function _cell.getData()
|
||||
return mData
|
||||
end
|
||||
|
||||
--------------------------------------------
|
||||
return _cell
|
||||
@@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7b643c7c6e0b84e33b2df87e36f47099
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user