Commit 6e4790e1 by 严久程

通话结束后增加接口调用

parent dcbc972e
......@@ -5,7 +5,7 @@ ext {
ydlPublishVersion = [
// -------------- 业务模块 --------------
//第三步 若干
"m-confide" : "0.0.48.42",
"m-confide" : "0.0.48.43",
"m-consultant" : "0.0.59.10",
"m-fm" : "0.0.29.9",
"m-user" : "0.0.60.8",
......@@ -39,7 +39,7 @@ ext {
"ydl-webview" : "0.0.38.31",
"ydl-media" : "0.0.21.6",
"ydl-pay" : "0.0.18.9",
"m-audioim" : "0.0.49.13",
"m-audioim" : "0.0.49.16",
"ydl-flutter-base": "0.0.14.14",
//以下 几乎不会动
......@@ -122,7 +122,7 @@ ext {
"ydl-webview" : "0.0.38.31",
"ydl-media" : "0.0.21.6",
"ydl-pay" : "0.0.18.9",
"m-audioim" : "0.0.49.13",
"m-audioim" : "0.0.49.16",
"ydl-flutter-base": "0.0.14.14",
//以下 几乎不会动
......
......@@ -154,6 +154,7 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
private var axbPhone: String? = null
//是否跳转到拨号页面
private var isJumpDail: Boolean = false
private var isShowAXB: Boolean = true
private var mPlayer: AudioPlayer? = null
private var vibrator: Vibrator? = null
private var handler: Handler? = null
......@@ -431,6 +432,7 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
listenerUid = intent.getStringExtra(IntentConstants.INTENT_LISTENER_UID)
listenId = intent.getStringExtra(IntentConstants.INTENT_LISTEN_ID)
commentUrl = intent.getStringExtra(IntentConstants.INTENT_COMMENT_URL)
isShowAXB = intent.getBooleanExtra(IntentConstants.INTENT_ISSHOWAXB,true)
val logBean = AgoraLogInfoBean(expertHeadUrl, expertName, channelId, remainTime, listenerUid, totalDuration, callId, listenId)
val content = Gson().toJson(logBean)
......@@ -477,6 +479,11 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
option.transform = 0
YDLImageCacheManager.showImage(this, expertHeadUrl, iv_head, option)
}
if(!isShowAXB){
tv_change_route.visibility=View.GONE
tv_change_time_counter.visibility=View.GONE
}
}
private fun setClickEvent() {
......@@ -756,11 +763,16 @@ class AudioHomeActivity : BaseMvpActivity<IAudioHomeActivityContract.View, IAudi
tv_change_doctor.text = "对方暂无应答,正在为您切换线路重播"
tv_change_doctor.visibility = View.VISIBLE
}
//切换线路按钮可见
tv_change_route.isEnabled = true
tv_change_route.text = "切换至传统电话"
if(!isShowAXB){
tv_change_route.visibility=View.GONE
}else{
//切换线路按钮可见
tv_change_route.isEnabled = true
tv_change_route.text = "切换至传统电话"
tv_change_route.setTextColor(ContextCompat.getColor(this, R.color.platform_white))
}
tv_change_route.setTextColor(ContextCompat.getColor(this, R.color.platform_white))
}
/**
......
......@@ -21,4 +21,5 @@ public interface IntentConstants {
String INTENT_TOTAL_DURATION= "intent_total_duration";
String INTENT_LISTEN_ID= "intent_listen_id";
String INTENT_COMMENT_URL= "intent_comment_url";
String INTENT_ISSHOWAXB= "intent_isshowaxb";
}
......@@ -6,34 +6,35 @@ import com.ydl.audioim.bean.ExpertInfoBean
/**
* 倾诉连接响应数据
*/
class ConfideConnectResponse{
class ConfideConnectResponse {
var dialDetail : DialDetail? = null
var listenOrderId : Long? = 0 //订单ID
var callId : String? = null //
var payId : String?=null //支付ID
var payTitle : String? = null //支付标题
var listenOrderPrice : Double? = null //订单金额
var userBaseInfoRespDto : UserBaseInfoRespDto?=null
var coupon : CouponData? = null //优惠信息
var dialDetail: DialDetail? = null
var listenOrderId: Long? = 0 //订单ID
var callId: String? = null //
var payId: String? = null //支付ID
var payTitle: String? = null //支付标题
var listenOrderPrice: Double? = null //订单金额
var userBaseInfoRespDto: UserBaseInfoRespDto? = null
var coupon: CouponData? = null //优惠信息
var isShowAxb = true
}
class DialDetail{
class DialDetail {
var agoraExpertInfo: ExpertInfoBean? = null
var callConnectType :Int ? = null
var dialReason : String? = null //连接失败原因
var dialStatus : Int? = null //连接状态
var phoneNu : String ?= null //axb号码
var callConnectType: Int? = null
var dialReason: String? = null //连接失败原因
var dialStatus: Int? = null //连接状态
var phoneNu: String? = null //axb号码
}
class UserBaseInfoRespDto{
var availableMoney : Double ? = null
var companyMoney : Double ? = null
var doctorId : Long ? = null
var phone : Long ? = null
var userType : String?=null
class UserBaseInfoRespDto {
var availableMoney: Double? = null
var companyMoney: Double? = null
var doctorId: Long? = null
var phone: Long? = null
var userType: String? = null
}
class CouponData{
var couponMoney:Double? = 0.00
class CouponData {
var couponMoney: Double? = 0.00
}
\ No newline at end of file
......@@ -84,7 +84,7 @@ class ConfideWebServiceImpl{
if (it.data?.dialDetail?.callConnectType?:-1==3){
//声网
it.data?.dialDetail?.agoraExpertInfo?:return@subscribe
callAgora(activity,id,it.data!!.dialDetail!!.agoraExpertInfo!!,it.data.callId?:"0",it.data.listenOrderId?:0L,tellData)
callAgora(activity,id,it.data!!.dialDetail!!.agoraExpertInfo!!,it.data.callId?:"0",it.data.listenOrderId?:0L,tellData,it.data.isShowAxb)
}else{
//axb
val dialog = AxbConfirmDialog(activity,1,object :AxbConfirmDialog.OnClickEnsureListener{
......@@ -114,7 +114,7 @@ class ConfideWebServiceImpl{
}
//启动声网电话
private fun callAgora(activity: Activity, confideId:Int, expertInfo : ExpertInfoBean, call_id:String, relation_id:Long, tellData: TellData?){
private fun callAgora(activity: Activity, confideId:Int, expertInfo : ExpertInfoBean, call_id:String, relation_id:Long, tellData: TellData?,isShowAXB:Boolean){
//3G以下或者其他不确定异常能判断出来的
if (!ConfideNetworkUtil.isWifiOr3G(activity)) {
CommonDialog.create(activity)
......@@ -156,6 +156,7 @@ class ConfideWebServiceImpl{
.withString(IntentConstants.INTENT_TOTAL_DURATION, expertInfo.totalDuration)
.withString(IntentConstants.INTENT_COMMENT_URL, expertInfo.commentUrl)
.withString(IntentConstants.INTENT_LISTEN_ID, confideId.toString())
.withBoolean(IntentConstants.INTENT_ISSHOWAXB,isShowAXB)
.navigation(activity)
}
}
......
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