Commit a2a50d54 by 徐健

增加测评首页

parent f6456cb1
......@@ -43,14 +43,14 @@ ext {
// -------------- 业务模块 --------------
//第三步 若干
"m-confide" : "0.0.31.8",
"m-confide" : "0.0.31.10",
"m-consultant" : "0.0.44",
"m-fm" : "0.0.21",
"m-user" : "0.0.34",
// 接入flutter的模块
"m-tests" : "0.0.12",
"m-muse" : "0.0.19",
"m-course" : "0.0.30",
"m-tests" : "0.0.13.5",
"m-muse" : "0.0.19.5",
"m-course" : "0.0.30.5",
//-------------- 业务模块 API 层 --------------
"m-audioim-api" : "0.0.5",
......@@ -70,13 +70,13 @@ ext {
"ydl-webview" : "0.0.28",
"ydl-media" : "0.0.14",
"ydl-pay" : "0.0.11",
"m-audioim" : "0.0.31.9",
"m-audioim" : "0.0.31.11",
//以下 几乎不会动
"router" : "0.0.1",
"ydl-net" : "0.0.2",
"ydl-utils" : "0.0.3",
"ydl-flutter-base": "0.0.5.12",
"ydl-flutter-base": "0.0.5.17",
]
ydlCompileVersion = [
......@@ -110,14 +110,14 @@ ext {
"ydl-webview" : "0.0.28",
"ydl-media" : "0.0.14",
"ydl-pay" : "0.0.11",
"m-audioim" : "0.0.31.9",
"m-audioim" : "0.0.31.11",
//以下 几乎不会动
"router" : "0.0.1",
"ydl-net" : "0.0.2",
"ydl-utils" : "0.0.3",
"ydl-flutter-base": "0.0.5.12",
"ydl-flutter-base": "0.0.5.17",
]
dependencies = [
......@@ -255,7 +255,7 @@ ext {
//flutter功能组件升级===>发布ydl-flutter组件===>引用flutter相关的业务模块
"ydl-flutter-base" : "com.ydl:ydl-flutter-base:${ydlCompileVersion["ydl-flutter-base"]}", //组件化项目中的flutter base模块
"ydl-flutter" : "com.ydl:ydl-flutter:0.0.15.5@aar", //flutter aar
"ydl-flutter" : "com.ydl:ydl-flutter:0.0.16.4@aar", //flutter aar
"ydl-flutter-sp" : "com.ydl:ydl-flutter-sp:0.0.2@aar", //flutter 缓存 aar
//基础组件 <<--- 先发这个,发完改这里的版本号
......
......@@ -75,7 +75,7 @@ dependencies {
kapt "com.alibaba:arouter-compiler:$arouter_compiler"
api "com.alibaba:arouter-api:$arouter_api"
api ('com.ydl:ydl-av:1.1.8@aar'){
api ('com.ydl:ydl-av:1.1.9@aar'){
transitive = true
}
......
......@@ -248,6 +248,24 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
onJoinChannelSuccess()
}
override fun onRtcStats(stats: IRtcEngineEventHandler.RtcStats?) {
super.onRtcStats(stats)
//因为用户端直接加入了频道,防止该回调执行时,专家还未加入频道,因此在连接成功之后,才进行频道人数判断
if (isConnectSuccess && null != stats?.users && stats.users == 1) {
com.yidianling.common.tools.ToastUtil.toastShort("专家已挂断")
leaveChannel()
}
}
override fun onConnectionStateChanged(state: Int, reason: Int) {
super.onConnectionStateChanged(state, reason)
// 3 网络连接被服务器中止 该情况现在是因为后端踢人逻辑
if (reason == 3) {
com.yidianling.common.tools.ToastUtil.toastShort("专家已挂断")
leaveChannel()
}
}
override fun onLeaveChannel(stats: IRtcEngineEventHandler.RtcStats?) {
super.onLeaveChannel(stats)
LogUtil.e("[agora]离开频道回调")
......@@ -391,6 +409,7 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
iv_hang_up.setOnClickListener {
if (isConnectSuccess) {
updateExpertStatus(false, 1)
userCloseCalling()
} else {
userCloseCalling()
}
......@@ -616,19 +635,23 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
dialPhone()
}
if(finishStatus==1){
var param = ConnectFinishCommand(listenerUid!!, relationId!!, "0",
remainTime!!.toInt() - localRemainTime!!, callId!!,
"0","0","$callStartTime",
"${System.currentTimeMillis()}",3)
// mPresenter.connectFinish(param)
}else{
//接通开始回调
if (finishStatus == 0) {
callStartTime = System.currentTimeMillis()
var param = ConnectStartCommand(listenerUid!!, relationId!!, callId!!,
"${System.currentTimeMillis()}","3","0","0","0","0")
// mPresenter.connectStart(param)
}
// if(finishStatus==1){
// var param = ConnectFinishCommand(listenerUid!!, relationId!!, "0",
// remainTime!!.toInt() - localRemainTime!!, callId!!,
// "0","0","$callStartTime",
// "${System.currentTimeMillis()}",3)
// mPresenter.connectFinish(param)
// }else{
// 接通开始回调
// callStartTime = System.currentTimeMillis()
// var param = ConnectStartCommand(listenerUid!!, relationId!!, callId!!,
// "${System.currentTimeMillis()}","3","0","0","0","0")
// mPresenter.connectStart(param)
// }
}
/**
......@@ -642,7 +665,11 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
}
override fun onClose() {
userCloseCalling()
// 如果声网未连接成功,切换axb的弹框是自动弹出的,当关闭弹框的时候,执行用户挂断操作
// 如果声网连接成功,点击右上角按钮弹出切换axb弹框,但是关闭时用户不执行挂断操作
if (!isConnectSuccess) {
userCloseCalling()
}
}
})
dialog.show()
......
......@@ -12,7 +12,7 @@ import org.json.JSONObject
@Route(path = "/ceshi/home")
class NewTestHomeActivity : BaseFlutterActivity() {
override fun initialRoute(): String {
return "native/test/home"
return "test/home"
}
override fun initChannelPlugin(jsonObject: JSONObject) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment