Commit 4f1038e5 by 严久程

声网

parent 19a761e2
......@@ -42,7 +42,7 @@ ext {
ydlPublishVersion = [
// -------------- 业务模块 --------------
//第三步 若干
"m-confide" : "0.0.48.7",
"m-confide" : "0.0.48.7.3",
"m-consultant" : "0.0.57.4",
"m-fm" : "0.0.29.3",
"m-user" : "0.0.58.2",
......@@ -75,7 +75,7 @@ ext {
"ydl-webview" : "0.0.37.1",
"ydl-media" : "0.0.20",
"ydl-pay" : "0.0.17",
"m-audioim" : "0.0.48.2",
"m-audioim" : "0.0.48.2.3",
"ydl-flutter-base": "0.0.10.9",
//以下 几乎不会动
......@@ -121,7 +121,7 @@ ext {
"ydl-webview" : "0.0.37.1",
"ydl-media" : "0.0.20",
"ydl-pay" : "0.0.17",
"m-audioim" : "0.0.48.2",
"m-audioim" : "0.0.48.2.3",
"ydl-flutter-base": "0.0.10.9",
//以下 几乎不会动
......
......@@ -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.2.0@aar'){
api ('com.ydl:ydl-av:1.2.1@aar'){
transitive = true
}
......
......@@ -248,7 +248,7 @@ class AudioHomeActivity :
override fun onApiCallExecuted(error: Int, api: String?, result: String?) {
super.onApiCallExecuted(error, api, result)
LogUtil.e("[agora]$api 已执行回调 $result")
// LogUtil.e("[agora]$api 已执行回调 $result")
}
......@@ -297,7 +297,7 @@ class AudioHomeActivity :
override fun onLastmileQuality(quality: Int) {
super.onLastmileQuality(quality)
LogUtil.e("[agora]网络质量报告回调${quality}")
// LogUtil.e("[agora]网络质量报告回调${quality}")
}
override fun onConnectionInterrupted() {
......@@ -328,19 +328,6 @@ class AudioHomeActivity :
}
//
/**
* 上传错误日志
* zhu 洪平要的,判别是移动端主动调的还是声网返的
*/
private fun uploadException(message: String, zhu: String = "") {
var time: String = (System.currentTimeMillis() / 1000).toString()
var uid: String =
ModularServiceManager.provide(IUserService::class.java).getUserInfo()?.uid!!
var payLoad = PayLoad(channelId ?: "0", time, uid, "1", "999", message)
var connectException = ConnectExceptionCommand(time + zhu, "2", "99", payLoad)
getPresenter().connectException(connectException)
}
override fun createPresenter(): IAudioHomeActivityContract.Presenter {
return AudioHomePresenterImpl()
}
......@@ -493,6 +480,7 @@ class AudioHomeActivity :
//RTC 回调
YDLRTMClient.instances.setCallListener(object : CallListener {
override fun onCallRecivedByPeer(response: CallLocalResponse?) {
playWaitingMusic()
//返回给主叫:被叫已收到呼叫邀请
LogUtil.i("[agora]${response?.calleeId}已收到呼叫邀请,频道号${response?.ChannelId}")
}
......@@ -638,7 +626,13 @@ class AudioHomeActivity :
.take(603)
.observeOn(AndroidSchedulers.mainThread())
.subscribe({
progress_view.setProgress(it.toFloat() / 2.5f)
var result = it.toFloat() / 2.5f
progress_view.setProgress(result)
if (result >= 100f && !iv_hang_up.isEnabled) {
//挂断按钮可点击
iv_hang_up.isEnabled = true
iv_hang_up.setImageResource(R.drawable.audioim_img_hang_up)
}
}, {
LogUtil.d(it.message)
}, {
......@@ -797,7 +791,7 @@ class AudioHomeActivity :
/**
* 30s等待完成,专家未接听
* 60s等待完成,专家未接听
*/
private fun waittingStatus() {
//挂断按钮可点击
......@@ -1120,6 +1114,21 @@ class AudioHomeActivity :
}
}
/**
* 上传错误日志
* zhu 洪平要的,判别是移动端主动调的还是声网返的
*/
private fun uploadException(message: String, zhu: String = "") {
var time: String = (System.currentTimeMillis() / 1000).toString()
var uid: String =
ModularServiceManager.provide(IUserService::class.java).getUserInfo()?.uid!!
var payLoad = PayLoad(channelId ?: "0", time, uid, "1", "999", message)
var connectException = ConnectExceptionCommand(time + zhu, "2", "99", payLoad)
getPresenter().connectException(connectException)
}
override fun finishActivity() {
leaveChannel()
}
......
package com.ydl.audioim.presenter
import android.annotation.SuppressLint
import com.ydl.audioim.BuildConfig
import com.ydl.ydl_av.chat.config.YDLChatParam
import com.ydl.audioim.contract.IAudioHomeActivityContract
......@@ -106,6 +107,7 @@ class AudioHomePresenterImpl : BasePresenter<IAudioHomeActivityContract.View, IA
/**
* 获取axb电话
*/
@SuppressLint("CheckResult")
override fun getAXBPhone(cmd: ConnectCommand) {
mModel.getAXBPhone(cmd)
.subscribeOn(Schedulers.io())
......@@ -113,7 +115,7 @@ class AudioHomePresenterImpl : BasePresenter<IAudioHomeActivityContract.View, IA
.doOnSubscribe { mView.showProgressView() }
.doAfterTerminate { mView.dismissProgressView() }
.subscribe({
if ("200".equals(it.code)){
if ("200" == it.code){
if(0==it.data?.dialDetail?.dialStatus?:-1){
//连接成功
if(it.data?.dialDetail?.callConnectType?:-1==1){
......
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