parent
fa7c35503e
commit
fefe0ec8b7
|
|
@ -19,4 +19,5 @@ object ReportType {
|
||||||
|
|
||||||
object ReportKey {
|
object ReportKey {
|
||||||
const val EVENT_CLIENT_UNI_RELEASE_WGT: String = "client.uni.release.wgt" //释放资源
|
const val EVENT_CLIENT_UNI_RELEASE_WGT: String = "client.uni.release.wgt" //释放资源
|
||||||
|
const val EVENT_CLIENT_UNI_SPEC_PAGE_LOAD: String = "client.uni.page.load" //页面加载
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -179,15 +179,25 @@ object UniAppUtils {
|
||||||
releaseWgt(uniMpId,reportViewModel){
|
releaseWgt(uniMpId,reportViewModel){
|
||||||
// 启动直达页面
|
// 启动直达页面
|
||||||
startUniMpToPage(context, uniMpId, uniMpType, pagePath)
|
startUniMpToPage(context, uniMpId, uniMpType, pagePath)
|
||||||
|
|
||||||
}
|
}
|
||||||
}else{
|
}else if(DCUniMPSDK.getInstance().isExistsApp(uniMpId)){
|
||||||
val uniMp = _uniMpFlow.value[uniMpId]
|
val uniMp = _uniMpFlow.value[uniMpId]
|
||||||
if(uniMp?.isRuning == true){
|
if(uniMp?.isRuning == true){
|
||||||
uniMp.showUniMP()
|
uniMp.showUniMP()
|
||||||
}
|
}
|
||||||
// 启动直达页面
|
// 启动直达页面
|
||||||
startUniMpToPage(context, uniMpId, uniMpType, pagePath)
|
startUniMpToPage(context, uniMpId, uniMpType, pagePath)
|
||||||
|
}else{
|
||||||
|
CenterToast.show("加载失败,请重试或联系客服!")
|
||||||
|
//事件提交
|
||||||
|
reportViewModel.requestReport(
|
||||||
|
ReportRequest(
|
||||||
|
ReportType.ERROR,
|
||||||
|
ReportKey.EVENT_CLIENT_UNI_SPEC_PAGE_LOAD,
|
||||||
|
uniMpId,
|
||||||
|
"加载指定页面"
|
||||||
|
)
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private fun startUniMpToPage(context: Context, uniMpId: String, uniMpType: String, pagePath: String){
|
private fun startUniMpToPage(context: Context, uniMpId: String, uniMpType: String, pagePath: String){
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue