[6.2.0]消息盒子司机端FM信息
@@ -8,38 +8,36 @@ import com.mogo.eagle.core.utilcode.util.SPUtils
|
||||
* @description 消息盒子配置
|
||||
* @since: 2022/12/1
|
||||
*/
|
||||
class MsgBoxConfig {
|
||||
object MsgBoxConfig {
|
||||
|
||||
companion object{
|
||||
//当前用户的Tab选择记录
|
||||
private const val userRecord = "USER_RECORD"
|
||||
//当前用户的Tab选择记录
|
||||
private const val userRecord = "USER_RECORD"
|
||||
|
||||
/**
|
||||
* 获取当前用户Tab选择记录
|
||||
*/
|
||||
fun getUserRecord(): Int{
|
||||
return SPUtils.getInstance().getInt(userRecord,0)
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置当前用户Tab选择记录
|
||||
*/
|
||||
fun setUserRecord(record: Int){
|
||||
SPUtils.getInstance().put(userRecord,record)
|
||||
}
|
||||
|
||||
//通知消息缓存列表
|
||||
@JvmField
|
||||
var noticeList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
//车辆系统信息缓存列表
|
||||
@JvmField
|
||||
var systemInfoList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
//录包信息缓存列表
|
||||
@JvmField
|
||||
var recordBagList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
//播放小智语音消息时的未播放消息缓存列表
|
||||
@JvmField
|
||||
var unPlayList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
/**
|
||||
* 获取当前用户Tab选择记录
|
||||
*/
|
||||
fun getUserRecord(): Int{
|
||||
return SPUtils.getInstance().getInt(userRecord,0)
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置当前用户Tab选择记录
|
||||
*/
|
||||
fun setUserRecord(record: Int){
|
||||
SPUtils.getInstance().put(userRecord,record)
|
||||
}
|
||||
|
||||
//通知消息缓存列表
|
||||
@JvmField
|
||||
var noticeList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
//车辆系统信息缓存列表
|
||||
@JvmField
|
||||
var systemInfoList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
//录包信息缓存列表
|
||||
@JvmField
|
||||
var recordBagList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
//播放小智语音消息时的未播放消息缓存列表
|
||||
@JvmField
|
||||
var unPlayList: ArrayList<MsgBoxBean> = ArrayList()
|
||||
|
||||
}
|
||||
@@ -0,0 +1,164 @@
|
||||
package com.mogo.eagle.core.function.msgbox
|
||||
|
||||
import com.zhjt.mogo.adas.data.bean.MogoReport
|
||||
|
||||
/**
|
||||
* FM信息对照表
|
||||
*/
|
||||
class MsgFmData{
|
||||
/**
|
||||
* 当出现多个建议操作时,按照整车下电重启、请求人工驾驶接管、请求平行驾驶接管、系统重启、联系硬件工程师、联系运维工程师、联系软件工程师优先级递减的顺序,只展示最高优先级的内容
|
||||
*/
|
||||
enum class FaultAction(
|
||||
val faultType: String,//故障处理类别
|
||||
val faultAction: String,//故障处理行为定义
|
||||
val faultActionCode: String,//故障处理行为标识
|
||||
val faultActionDesc: String,//故障处理行为描述
|
||||
val faultLevel: Int//故障处理级别
|
||||
){
|
||||
//请求平行驾驶接管
|
||||
FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER("恢复策略","请求平行驾驶接管","FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER","如planing出站时,规划失败",5),
|
||||
//请求人工驾驶接管
|
||||
FM_ACT_NEED_MANNUAL_DERVING("恢复策略","请求人工驾驶接管","FM_ACT_NEED_MANNUAL_DERVING","如planing规划失败,且存在弱网判断",6),
|
||||
//系统重启
|
||||
FM_ACT_NEED_RESTART_SYSTEM("恢复策略","系统重启","FM_ACT_NEED_RESTART_SYSTEM","如检测到出现多个节点奔溃",4),
|
||||
//整车下电重启
|
||||
FM_ACT_MUST_VEHICLE_POWER_RESET("恢复策略","整车下电重启","FM_ACT_MUST_VEHICLE_POWER_RESET","如底盘无数据,需要下电重启",7),
|
||||
//请联系硬件工程师
|
||||
FM_ACT_CONTACT_HARDWARE_ENGINEER("人工处理","请联系硬件工程师","FM_ACT_CONTACT_HARDWARE_ENGINEER","硬件接线,域控启动等故障",3),
|
||||
//请联系运维工程师
|
||||
FM_ACT_CONTACT_OPERATIONS_ENGINEER("人工处理","请联系运维工程师","FM_ACT_CONTACT_OPERATIONS_ENGINEER","系统配置不对,网络等故障",2),
|
||||
//请联系软件工程师
|
||||
FM_ACT_CONTACT_SOFTWARE_ENGINEER("人工处理","请联系软件工程师","FM_ACT_CONTACT_SOFTWARE_ENGINEER","节点挂掉,无法启动等故障",1);
|
||||
|
||||
companion object{
|
||||
|
||||
//获取故障建议操作级别
|
||||
fun getFaultLevel(faultActionCode: String): Int{
|
||||
return when(faultActionCode){
|
||||
//请求平行驾驶接管
|
||||
FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER.faultActionCode -> FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER.faultLevel
|
||||
//请求人工驾驶接管
|
||||
FM_ACT_NEED_MANNUAL_DERVING.faultActionCode -> FM_ACT_NEED_MANNUAL_DERVING.faultLevel
|
||||
//系统重启
|
||||
FM_ACT_NEED_RESTART_SYSTEM.faultActionCode -> FM_ACT_NEED_RESTART_SYSTEM.faultLevel
|
||||
//整车下电重启
|
||||
FM_ACT_MUST_VEHICLE_POWER_RESET.faultActionCode -> FM_ACT_MUST_VEHICLE_POWER_RESET.faultLevel
|
||||
//请联系硬件工程师
|
||||
FM_ACT_CONTACT_HARDWARE_ENGINEER.faultActionCode -> FM_ACT_CONTACT_HARDWARE_ENGINEER.faultLevel
|
||||
//请联系运维工程师
|
||||
FM_ACT_CONTACT_OPERATIONS_ENGINEER.faultActionCode ->FM_ACT_CONTACT_OPERATIONS_ENGINEER.faultLevel
|
||||
//请联系软件工程师
|
||||
FM_ACT_CONTACT_SOFTWARE_ENGINEER.faultActionCode -> FM_ACT_CONTACT_SOFTWARE_ENGINEER.faultLevel
|
||||
else -> 0
|
||||
}
|
||||
}
|
||||
|
||||
//获取故障建议操作
|
||||
fun getFaultAction(faultActionLevel: Int): String{
|
||||
return when(faultActionLevel){
|
||||
//请求平行驾驶接管
|
||||
FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER.faultLevel -> FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER.faultAction
|
||||
//请求人工驾驶接管
|
||||
FM_ACT_NEED_MANNUAL_DERVING.faultLevel -> FM_ACT_NEED_MANNUAL_DERVING.faultAction
|
||||
//系统重启
|
||||
FM_ACT_NEED_RESTART_SYSTEM.faultLevel -> FM_ACT_NEED_RESTART_SYSTEM.faultAction
|
||||
//整车下电重启
|
||||
FM_ACT_MUST_VEHICLE_POWER_RESET.faultLevel -> FM_ACT_MUST_VEHICLE_POWER_RESET.faultAction
|
||||
//请联系硬件工程师
|
||||
FM_ACT_CONTACT_HARDWARE_ENGINEER.faultLevel -> FM_ACT_CONTACT_HARDWARE_ENGINEER.faultAction
|
||||
//请联系运维工程师
|
||||
FM_ACT_CONTACT_OPERATIONS_ENGINEER.faultLevel ->FM_ACT_CONTACT_OPERATIONS_ENGINEER.faultAction
|
||||
//请联系软件工程师
|
||||
FM_ACT_CONTACT_SOFTWARE_ENGINEER.faultLevel -> FM_ACT_CONTACT_SOFTWARE_ENGINEER.faultAction
|
||||
else -> "暂无"
|
||||
}
|
||||
}
|
||||
|
||||
//获取故障建议操作Code值
|
||||
fun getFaultActionCode(faultActionLevel: Int): String{
|
||||
return when(faultActionLevel){
|
||||
//请求平行驾驶接管
|
||||
FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER.faultLevel -> FM_ACT_NEED_PARALLEL_DERVING_TAKEOVER.faultActionCode
|
||||
//请求人工驾驶接管
|
||||
FM_ACT_NEED_MANNUAL_DERVING.faultLevel -> FM_ACT_NEED_MANNUAL_DERVING.faultActionCode
|
||||
//系统重启
|
||||
FM_ACT_NEED_RESTART_SYSTEM.faultLevel -> FM_ACT_NEED_RESTART_SYSTEM.faultActionCode
|
||||
//整车下电重启
|
||||
FM_ACT_MUST_VEHICLE_POWER_RESET.faultLevel -> FM_ACT_MUST_VEHICLE_POWER_RESET.faultActionCode
|
||||
//请联系硬件工程师
|
||||
FM_ACT_CONTACT_HARDWARE_ENGINEER.faultLevel -> FM_ACT_CONTACT_HARDWARE_ENGINEER.faultActionCode
|
||||
//请联系运维工程师
|
||||
FM_ACT_CONTACT_OPERATIONS_ENGINEER.faultLevel ->FM_ACT_CONTACT_OPERATIONS_ENGINEER.faultActionCode
|
||||
//请联系软件工程师
|
||||
FM_ACT_CONTACT_SOFTWARE_ENGINEER.faultLevel -> FM_ACT_CONTACT_SOFTWARE_ENGINEER.faultActionCode
|
||||
else -> ""
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
enum class FaultResult(
|
||||
val resultType: String,//影响类别
|
||||
val resultDefine: String,//故障影响定义
|
||||
val resultCode: String,//故障影响的标识
|
||||
val resultDesc: String//后果对应的处理描述
|
||||
){
|
||||
//无法作业
|
||||
FM_RST_FUNCTION_LOST("功能影响","无法作业","FM_RST_FUNCTION_LOST","需要禁止作业,如扫盘故障,清扫车无法清扫作业"),
|
||||
//无法开放运营
|
||||
FM_RST_FORBID_OPEN_WORK("功能影响","无法开放运营","FM_RST_FORBID_OPEN_WORK","需要禁止运营,如安全带故障,可以自驾,不能载人"),
|
||||
//无法平行驾驶
|
||||
FM_RST_FORBID_PARALLEL_DERVING("驾驶影响","无法平行驾驶","FM_RST_FORBID_PARALLEL_DERVING","需要禁止平行驾驶"),
|
||||
//无法自动驾驶
|
||||
FM_RST_FORBID_AUTOPILOT_DERVING("驾驶影响","无法自动驾驶","FM_RST_FORBID_AUTOPILOT_DERVING","需要禁止自驾"),
|
||||
//无法手动驾驶
|
||||
FM_RST_FORBID_MANNUAL_DERVING("驾驶影响","无法手动驾驶","FM_RST_FORBID_MANNUAL_DERVING","需要禁止行车,如底盘存在故障,需要通知出来"),
|
||||
//失控,无法策略停车
|
||||
FM_RST_OUT_OF_CONTROL("安全影响","失控,无法策略停车","FM_RST_OUT_OF_CONTROL","需要立即紧急通知到人,车辆失控,如驾驶中controller挂掉,发送102重启");
|
||||
|
||||
companion object{
|
||||
//获取结果原因描述
|
||||
fun getResultDefine(resultCode: String): String{
|
||||
return when(resultCode){
|
||||
//无法作业
|
||||
FM_RST_FUNCTION_LOST.resultCode -> FM_RST_FUNCTION_LOST.resultDefine
|
||||
//无法开放运营
|
||||
FM_RST_FORBID_OPEN_WORK.resultCode -> FM_RST_FORBID_OPEN_WORK.resultDefine
|
||||
//无法平行驾驶
|
||||
FM_RST_FORBID_PARALLEL_DERVING.resultCode -> FM_RST_FORBID_PARALLEL_DERVING.resultDefine
|
||||
//无法自动驾驶
|
||||
FM_RST_FORBID_AUTOPILOT_DERVING.resultCode -> FM_RST_FORBID_AUTOPILOT_DERVING.resultDefine
|
||||
//无法手动驾驶
|
||||
FM_RST_FORBID_MANNUAL_DERVING.resultCode -> FM_RST_FORBID_MANNUAL_DERVING.resultDefine
|
||||
//失控,无法策略停车
|
||||
FM_RST_OUT_OF_CONTROL.resultCode -> FM_RST_OUT_OF_CONTROL.resultDefine
|
||||
else -> "暂无"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
companion object{
|
||||
|
||||
@JvmStatic
|
||||
fun getFmPolicyName(policyCode: String?): String{
|
||||
return when(policyCode){
|
||||
"FM_DP_NO_ACTION" -> "报告"
|
||||
"FM_DP_ONLY_WARNING" -> "警示"
|
||||
"FM_DP_SPEED_LIMIT1" -> "一级降速"
|
||||
"FM_DP_SPEED_LIMIT2" -> "二级降速"
|
||||
"FM_DP_SPEED_LIMIT3" -> "三级降速"
|
||||
"FM_DP_PNC_CHOOSE_STOP" -> "择机靠边停车"
|
||||
"FM_DP_COMFORTABLE_STOP" -> "立刻舒适停车"
|
||||
"FM_DP_EMERGENCY_STOP" -> "就地紧急停车"
|
||||
else -> "暂无"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -9,6 +9,7 @@ import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
import com.mogo.eagle.core.data.msgbox.FMInfoMsg
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxCountDownBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgCategory
|
||||
@@ -21,6 +22,7 @@ import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.DriverMsgBoxBubbleAdapter
|
||||
import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
|
||||
import com.mogo.eagle.core.utilcode.util.SoundPoolUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import kotlinx.android.synthetic.main.layout_driver_msg_box_bubble.view.*
|
||||
|
||||
@@ -98,7 +100,21 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
|
||||
//todo 过滤MAP系统异常报警
|
||||
} else if(category == MsgCategory.FM_INFO){
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
showData(msgBoxBean)
|
||||
//属于停车警示(包括择机靠边停车、立即舒适停车、就地紧急停车)时,需要弹出消息气泡并伴有提示音
|
||||
val fmInfoMsg = msgBoxBean.bean as FMInfoMsg
|
||||
if(fmInfoMsg.policyCode == "FM_DP_PNC_CHOOSE_STOP" //择机靠边停车
|
||||
|| fmInfoMsg.policyCode == "FM_DP_COMFORTABLE_STOP" //立刻舒适停车
|
||||
|| fmInfoMsg.policyCode == "FM_DP_EMERGENCY_STOP" //就地紧急停车
|
||||
){
|
||||
//语音提示
|
||||
try {
|
||||
SoundPoolUtils.getSoundPool().playSoundWithRedId(context,R.raw.weak_net_tips)
|
||||
}catch (e: Exception){
|
||||
e.printStackTrace()
|
||||
}
|
||||
//展示消息
|
||||
showData(msgBoxBean)
|
||||
}
|
||||
} else{
|
||||
if(msgBoxBean.sourceType == DataSourceType.SUMMARY){
|
||||
//在一次订单中汇总消息只展示一次
|
||||
|
||||
@@ -46,7 +46,7 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
}
|
||||
private val TAG = "DriverMsgBoxListView"
|
||||
private var noticeList: ArrayList<MsgBoxBean> ?= null //通知消息列表
|
||||
private var fmList: ArrayList<MsgBoxBean> ?= null //FM信息消息列表
|
||||
private var fmList: ArrayList<MsgBoxBean> ?= ArrayList() //FM信息消息列表
|
||||
private var ipcReportList: ArrayList<MsgBoxBean> ?= null //车辆系统信息消息列表
|
||||
private var badCaseList: ArrayList<MsgBoxBean> ?= null//录包消息列表
|
||||
private var driverMsgBoxListAdapter: DriverMsgBoxListAdapter ?=null
|
||||
@@ -232,6 +232,7 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
override fun onDataChanged(category: MsgCategory, msgBoxList: MsgBoxBean) {
|
||||
UiThreadHandler.post({
|
||||
when (category) {
|
||||
//通知
|
||||
MsgCategory.NOTICE -> {
|
||||
if(msgBoxList.sourceType == DataSourceType.SUMMARY){
|
||||
//在一次订单中汇总消息只展示一次
|
||||
@@ -249,18 +250,28 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
}
|
||||
//FM信息
|
||||
MsgCategory.FM_INFO -> {
|
||||
fmList?.add(0,msgBoxList)
|
||||
if(MsgBoxConfig.getUserRecord() == 1){
|
||||
fmList?.let { driverMsgBoxListAdapter?.setData(it) }
|
||||
}
|
||||
}
|
||||
//系统信息
|
||||
MsgCategory.SYS_INFO -> {
|
||||
ipcReportList?.add(0,msgBoxList)
|
||||
if(MsgBoxConfig.getUserRecord() == 1){
|
||||
if(MsgBoxConfig.getUserRecord() == 2){
|
||||
ipcReportList?.let { driverMsgBoxListAdapter?.setData(it) }
|
||||
}
|
||||
}
|
||||
//录包
|
||||
MsgCategory.RECORD_BAG -> {
|
||||
badCaseList?.add(0,msgBoxList)
|
||||
if(MsgBoxConfig.getUserRecord() == 2){
|
||||
if(MsgBoxConfig.getUserRecord() == 3){
|
||||
badCaseList?.let { driverMsgBoxListAdapter?.setData(it) }
|
||||
}
|
||||
}
|
||||
else -> {}
|
||||
}
|
||||
},UiThreadHandler.MODE.QUEUE)
|
||||
}
|
||||
|
||||
@@ -19,6 +19,8 @@ import com.mogo.eagle.core.function.call.hmi.CallerHmiManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
|
||||
import com.mogo.eagle.core.function.msgbox.MsgFmData
|
||||
import com.mogo.eagle.core.utilcode.mogo.glide.GlideApp
|
||||
import com.mogo.eagle.core.utilcode.mogo.glide.transform.GlideRoundedCornersTransform
|
||||
import com.mogo.eagle.core.utilcode.util.TimeUtils
|
||||
@@ -138,6 +140,7 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
holder.tvOperationDoorContent.text = operationDoorMsg.content
|
||||
}
|
||||
}
|
||||
//系统信息消息
|
||||
is BubbleReportHolder -> {
|
||||
data?.let {
|
||||
val msgBoxBean = it[position].msgBoxBean
|
||||
@@ -154,6 +157,7 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
}
|
||||
}
|
||||
}
|
||||
//云公告消息
|
||||
is BubbleNoticeHolder -> {
|
||||
data?.let {
|
||||
val msgBoxBean = it[position].msgBoxBean.bean
|
||||
@@ -193,6 +197,7 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
}
|
||||
}
|
||||
}
|
||||
//V2X消息
|
||||
is BubbleV2XHolder -> {
|
||||
data?.let {
|
||||
val msgBoxBean = it[position].msgBoxBean
|
||||
@@ -211,6 +216,7 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
}
|
||||
}
|
||||
}
|
||||
//汇总消息
|
||||
is BubbleSummaryHolder -> {
|
||||
data?.let {
|
||||
val summaryMsg = it[position].msgBoxBean.bean as V2XMsg
|
||||
@@ -218,10 +224,35 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
holder.tvSummaryContent.text = summaryMsg.content
|
||||
}
|
||||
}
|
||||
//FM信息
|
||||
is BubbleFmHolder ->{
|
||||
data?.let {
|
||||
val fmMsg = it[position].msgBoxBean.bean as FMInfoMsg
|
||||
|
||||
holder.tvBubbleFmFault.text = MsgFmData.getFmPolicyName(fmMsg.policyCode)
|
||||
if(fmMsg.policyTime == null){
|
||||
holder.tvBubbleFmTime.text = TimeUtils.millis2String(it[position].msgBoxBean.timestamp,getHourMinFormat())
|
||||
}else{
|
||||
holder.tvBubbleFmTime.text = TimeUtils.millis2String(fmMsg.policyTime!!,getHourMinFormat())
|
||||
}
|
||||
if(fmMsg.fmInfoList?.size == 0){
|
||||
holder.tvBubbleFmFaultAction.text = "建议操作:暂无"
|
||||
}else{
|
||||
var curFaultLevel = 0 //默认级别,遍历数组找出级别最高的(level数越小大,级别越高)
|
||||
fmMsg.fmInfoList?.forEach { faultInfo ->
|
||||
if(faultInfo.faultActionCount>0){
|
||||
faultInfo.faultActionList.forEach {actionCode ->
|
||||
//获取建议操作级别,得到建议操作级别最高的操作
|
||||
if(MsgFmData.FaultAction.getFaultLevel(actionCode) > curFaultLevel){
|
||||
curFaultLevel = MsgFmData.FaultAction.getFaultLevel(actionCode)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
val faultAction = MsgFmData.FaultAction.getFaultAction(curFaultLevel)
|
||||
//当出现多个建议操作时,按照整车下电重启、请求人工驾驶接管、请求平行驾驶接管、系统重启、联系硬件工程师、
|
||||
// 联系运维工程师、联系软件工程师优先级递减的顺序,只展示最高优先级的内容
|
||||
holder.tvBubbleFmFaultAction.text = "${faultAction}(${MsgFmData.FaultAction.getFaultActionCode(curFaultLevel)})"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -335,7 +366,9 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
|
||||
//FM消息
|
||||
class BubbleFmHolder(itemView: View): RecyclerView.ViewHolder(itemView){
|
||||
|
||||
var tvBubbleFmFault: TextView = itemView.findViewById(R.id.tvBubbleFmFault)
|
||||
var tvBubbleFmFaultAction: TextView = itemView.findViewById(R.id.tvBubbleFmFaultAction)
|
||||
var tvBubbleFmTime: TextView = itemView.findViewById(R.id.tvBubbleFmTime)
|
||||
}
|
||||
|
||||
fun setChangeListener(listener: ChangeViewListener){
|
||||
|
||||
@@ -18,6 +18,7 @@ import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.msgbox.MsgFmData
|
||||
import com.mogo.eagle.core.utilcode.mogo.glide.GlideApp
|
||||
import com.mogo.eagle.core.utilcode.mogo.glide.transform.GlideRoundedCornersTransform
|
||||
import com.mogo.eagle.core.utilcode.util.ResourceUtils.getDrawable
|
||||
@@ -138,7 +139,195 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
//FM信息
|
||||
is FmInfoHolder -> {
|
||||
data?.let {
|
||||
|
||||
val fmInfoMsg = it[position].bean as FMInfoMsg
|
||||
//时间显示
|
||||
holder.tvFmTimeOpen.text =
|
||||
"时间:${fmInfoMsg.policyTime?.let { it1 -> TimeUtils.millis2String(it1) }}"
|
||||
holder.tvFmTimeNormal.text =
|
||||
"时间:${fmInfoMsg.policyTime?.let { it1 -> TimeUtils.millis2String(it1) }}"
|
||||
holder.tvFmTime.text =
|
||||
fmInfoMsg.policyTime?.let { it1 -> TimeUtils.millis2String(it1,getHourMinFormat()) }
|
||||
//不同级别的Icon显示
|
||||
if(fmInfoMsg.policyCode == "FM_DP_ONLY_WARNING"){
|
||||
//警示
|
||||
holder.ivFmImageNormal.setImageDrawable(getDrawable(R.drawable.icon_fm_warning_normal))
|
||||
holder.ivFmImageOpen.setImageDrawable(getDrawable(R.drawable.icon_fm_warning_open))
|
||||
}else if(fmInfoMsg.policyCode == "FM_DP_SPEED_LIMIT1"
|
||||
|| fmInfoMsg.policyCode == "FM_DP_SPEED_LIMIT2"
|
||||
|| fmInfoMsg.policyCode == "FM_DP_SPEED_LIMIT3"){
|
||||
//降速行驶
|
||||
holder.ivFmImageNormal.setImageDrawable(getDrawable(R.drawable.icon_fm_reduce_normal))
|
||||
holder.ivFmImageOpen.setImageDrawable(getDrawable(R.drawable.icon_fm_reduce_open))
|
||||
}else if(fmInfoMsg.policyCode == "FM_DP_PNC_CHOOSE_STOP"
|
||||
|| fmInfoMsg.policyCode == "FM_DP_COMFORTABLE_STOP"
|
||||
|| fmInfoMsg.policyCode == "FM_DP_EMERGENCY_STOP"){
|
||||
//安全停车
|
||||
holder.ivFmImageNormal.setImageDrawable(getDrawable(R.drawable.icon_fm_stop_normal))
|
||||
holder.ivFmImageOpen.setImageDrawable(getDrawable(R.drawable.icon_fm_stop_open))
|
||||
}
|
||||
//Title
|
||||
holder.tvFmTitleNormal.text = MsgFmData.getFmPolicyName(fmInfoMsg.policyCode)
|
||||
holder.tvFmTitleOpen.text = MsgFmData.getFmPolicyName(fmInfoMsg.policyCode)
|
||||
//建议操作
|
||||
if(fmInfoMsg.fmInfoList.isNullOrEmpty()){
|
||||
//建议操作暂无
|
||||
holder.tvFmActionOpen.text = "建议操作:暂无"
|
||||
holder.tvFmActionNormal.text = "建议操作:暂无"
|
||||
}else{
|
||||
val receiveFaultLevel = ArrayList<Int>()
|
||||
fmInfoMsg.fmInfoList!!.forEach { info ->
|
||||
if(info.faultActionCount != 0){
|
||||
info.faultActionList.forEach { action ->
|
||||
//如果不包含此故障Level,则进行添加
|
||||
if(!receiveFaultLevel.contains(MsgFmData.FaultAction.getFaultLevel(action))){
|
||||
receiveFaultLevel.add(MsgFmData.FaultAction.getFaultLevel(action))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//对faultLevel集合进行排序,按照顺序输出建议操作
|
||||
if(receiveFaultLevel.size > 0){
|
||||
val faultActionStr: StringBuilder = StringBuilder()
|
||||
faultActionStr.append("建议操作:")
|
||||
receiveFaultLevel.sorted()
|
||||
receiveFaultLevel.forEach {level->
|
||||
faultActionStr.append(MsgFmData.FaultAction.getFaultAction(level))
|
||||
faultActionStr.append("(")
|
||||
faultActionStr.append(MsgFmData.FaultAction.getFaultActionCode(level))
|
||||
faultActionStr.append(")")
|
||||
}
|
||||
holder.tvFmActionOpen.text = faultActionStr.toString()
|
||||
holder.tvFmActionNormal.text = faultActionStr.toString()
|
||||
}else{
|
||||
holder.tvFmActionOpen.text = "建议操作:暂无"
|
||||
holder.tvFmActionNormal.text = "建议操作:暂无"
|
||||
}
|
||||
}
|
||||
//故障策略
|
||||
holder.tvFmFaultOpen.text = "故障策略:${MsgFmData.getFmPolicyName(fmInfoMsg.policyCode)}(${fmInfoMsg.policyCode})"
|
||||
//故障原因
|
||||
if(fmInfoMsg.fmInfoList.isNullOrEmpty()){
|
||||
holder.tvFmReasonOpen.text = "故障原因:暂无"
|
||||
}else{
|
||||
val fmFaultReason = StringBuilder()
|
||||
fmFaultReason.append("故障原因:")
|
||||
for((index,info) in fmInfoMsg.fmInfoList!!.withIndex()){
|
||||
fmFaultReason.append(info.faultName)
|
||||
fmFaultReason.append("(")
|
||||
fmFaultReason.append(info.faultId)
|
||||
fmFaultReason.append(")")
|
||||
if(index!=(fmInfoMsg.fmInfoList!!.size-1)){
|
||||
fmFaultReason.append("/")
|
||||
}
|
||||
}
|
||||
holder.tvFmReasonOpen.text = fmFaultReason.toString()
|
||||
}
|
||||
//故障后果
|
||||
if(fmInfoMsg.fmInfoList.isNullOrEmpty()){
|
||||
holder.tvFmResultOpen.text = "故障后果:暂无"
|
||||
}else{
|
||||
val fmFaultResult = StringBuilder()
|
||||
fmFaultResult.append("故障后果:")
|
||||
fmInfoMsg.fmInfoList!!.forEach { info->
|
||||
if(info.faultResultCount != 0){
|
||||
info.faultResultList.forEach { result->
|
||||
fmFaultResult.append(MsgFmData.FaultResult.getResultDefine(result))
|
||||
fmFaultResult.append("(")
|
||||
fmFaultResult.append(result)
|
||||
fmFaultResult.append(")")
|
||||
fmFaultResult.append("/")
|
||||
}
|
||||
}
|
||||
}
|
||||
if(fmFaultResult.endsWith("/")){
|
||||
holder.tvFmResultOpen.text = fmFaultResult.deleteCharAt(fmFaultResult.lastIndex).toString()
|
||||
}else{
|
||||
holder.tvFmResultOpen.text = "故障后果:暂无"
|
||||
}
|
||||
}
|
||||
//对布局进行展开折叠操作
|
||||
if(fmInfoMsg.isShow){
|
||||
holder.tvFmStatusSelect.setCompoundDrawablesWithIntrinsicBounds(
|
||||
getDrawable(R.drawable.icon_msg_close),
|
||||
null,
|
||||
null,
|
||||
null
|
||||
)
|
||||
holder.tvFmStatusSelect.text = "折叠"
|
||||
holder.ivFmImageNormal.visibility = View.GONE
|
||||
holder.tvFmTitleNormal.visibility = View.GONE
|
||||
holder.tvFmTimeNormal.visibility = View.GONE
|
||||
holder.tvFmActionNormal.visibility = View.GONE
|
||||
holder.ivFmImageOpen.visibility = View.VISIBLE
|
||||
holder.tvFmTitleOpen.visibility = View.VISIBLE
|
||||
holder.tvFmTimeOpen.visibility = View.VISIBLE
|
||||
holder.tvFmActionOpen.visibility = View.VISIBLE
|
||||
holder.tvFmFaultOpen.visibility = View.VISIBLE
|
||||
holder.tvFmReasonOpen.visibility = View.VISIBLE
|
||||
holder.tvFmResultOpen.visibility = View.VISIBLE
|
||||
}else{
|
||||
holder.tvFmStatusSelect.setCompoundDrawablesWithIntrinsicBounds(
|
||||
getDrawable(R.drawable.icon_msg_open),
|
||||
null,
|
||||
null,
|
||||
null
|
||||
)
|
||||
holder.tvFmStatusSelect.text = "展开"
|
||||
holder.ivFmImageNormal.visibility = View.VISIBLE
|
||||
holder.tvFmTitleNormal.visibility = View.VISIBLE
|
||||
holder.tvFmTimeNormal.visibility = View.VISIBLE
|
||||
holder.tvFmActionNormal.visibility = View.VISIBLE
|
||||
holder.ivFmImageOpen.visibility = View.GONE
|
||||
holder.tvFmTitleOpen.visibility = View.GONE
|
||||
holder.tvFmTimeOpen.visibility = View.GONE
|
||||
holder.tvFmActionOpen.visibility = View.GONE
|
||||
holder.tvFmFaultOpen.visibility = View.GONE
|
||||
holder.tvFmReasonOpen.visibility = View.GONE
|
||||
holder.tvFmResultOpen.visibility = View.GONE
|
||||
}
|
||||
holder.tvFmStatusSelect.setOnClickListener{
|
||||
if(!fmInfoMsg.isShow){
|
||||
fmInfoMsg.isShow = true
|
||||
holder.tvFmStatusSelect.setCompoundDrawablesWithIntrinsicBounds(
|
||||
getDrawable(R.drawable.icon_msg_close),
|
||||
null,
|
||||
null,
|
||||
null
|
||||
)
|
||||
holder.tvFmStatusSelect.text = "折叠"
|
||||
holder.ivFmImageNormal.visibility = View.GONE
|
||||
holder.tvFmTitleNormal.visibility = View.GONE
|
||||
holder.tvFmTimeNormal.visibility = View.GONE
|
||||
holder.tvFmActionNormal.visibility = View.GONE
|
||||
holder.ivFmImageOpen.visibility = View.VISIBLE
|
||||
holder.tvFmTitleOpen.visibility = View.VISIBLE
|
||||
holder.tvFmTimeOpen.visibility = View.VISIBLE
|
||||
holder.tvFmActionOpen.visibility = View.VISIBLE
|
||||
holder.tvFmFaultOpen.visibility = View.VISIBLE
|
||||
holder.tvFmReasonOpen.visibility = View.VISIBLE
|
||||
holder.tvFmResultOpen.visibility = View.VISIBLE
|
||||
}else{
|
||||
fmInfoMsg.isShow = false
|
||||
holder.tvFmStatusSelect.setCompoundDrawablesWithIntrinsicBounds(
|
||||
getDrawable(R.drawable.icon_msg_open),
|
||||
null,
|
||||
null,
|
||||
null
|
||||
)
|
||||
holder.tvFmStatusSelect.text = "展开"
|
||||
holder.ivFmImageNormal.visibility = View.VISIBLE
|
||||
holder.tvFmTitleNormal.visibility = View.VISIBLE
|
||||
holder.tvFmTimeNormal.visibility = View.VISIBLE
|
||||
holder.tvFmActionNormal.visibility = View.VISIBLE
|
||||
holder.ivFmImageOpen.visibility = View.GONE
|
||||
holder.tvFmTitleOpen.visibility = View.GONE
|
||||
holder.tvFmTimeOpen.visibility = View.GONE
|
||||
holder.tvFmActionOpen.visibility = View.GONE
|
||||
holder.tvFmFaultOpen.visibility = View.GONE
|
||||
holder.tvFmReasonOpen.visibility = View.GONE
|
||||
holder.tvFmResultOpen.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//系统信息
|
||||
@@ -468,7 +657,19 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
|
||||
//FM信息
|
||||
class FmInfoHolder(itemView: View) : RecyclerView.ViewHolder(itemView){
|
||||
|
||||
var ivFmImageNormal: ImageView = itemView.findViewById(R.id.ivFmImageNormal) //故障级别图标
|
||||
var tvFmTitleNormal: TextView = itemView.findViewById(R.id.tvFmTitleNormal) //标题展示故障策略
|
||||
var tvFmTimeNormal: TextView = itemView.findViewById(R.id.tvFmTimeNormal) //时间
|
||||
var tvFmStatusSelect: TextView = itemView.findViewById(R.id.tvFmStatusSelect) //展开折叠按钮
|
||||
var tvFmActionNormal: TextView = itemView.findViewById(R.id.tvFmActionNormal) //建议操作
|
||||
var tvFmTime: TextView = itemView.findViewById(R.id.tvFmTime) //时间
|
||||
var ivFmImageOpen: ImageView = itemView.findViewById(R.id.ivFmImageOpen) //展开时图标
|
||||
var tvFmTitleOpen: TextView = itemView.findViewById(R.id.tvFmTitleOpen) //标题文案为故障策略
|
||||
var tvFmTimeOpen: TextView = itemView.findViewById(R.id.tvFmTimeOpen) //发生时间
|
||||
var tvFmActionOpen: TextView = itemView.findViewById(R.id.tvFmActionOpen) //建议操作
|
||||
var tvFmFaultOpen: TextView = itemView.findViewById(R.id.tvFmFaultOpen) //故障策略
|
||||
var tvFmReasonOpen: TextView = itemView.findViewById(R.id.tvFmReasonOpen) //故障原因
|
||||
var tvFmResultOpen: TextView = itemView.findViewById(R.id.tvFmResultOpen) //后果
|
||||
}
|
||||
|
||||
//车辆系统信息
|
||||
|
||||
|
After Width: | Height: | Size: 15 KiB |
|
After Width: | Height: | Size: 3.1 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 2.9 KiB |
|
After Width: | Height: | Size: 16 KiB |
|
After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 3.3 KiB |
@@ -1,17 +1,198 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="804dp"
|
||||
android:layout_width="@dimen/dp_804"
|
||||
android:layout_height="wrap_content"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#53000000"
|
||||
app:roundLayoutRadius="24dp"
|
||||
app:roundLayoutRadius="@dimen/dp_24"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginStart="30dp"
|
||||
android:layout_marginEnd="30dp"
|
||||
android:layout_marginTop="7dp"
|
||||
android:layout_marginBottom="7dp"
|
||||
android:layout_marginStart="@dimen/dp_30"
|
||||
android:layout_marginEnd="@dimen/dp_30"
|
||||
android:layout_marginTop="@dimen/dp_7"
|
||||
android:layout_marginBottom="@dimen/dp_7"
|
||||
>
|
||||
|
||||
<!--故障级别图标-->
|
||||
<ImageView
|
||||
android:id="@+id/ivFmImageNormal"
|
||||
android:layout_width="@dimen/dp_110"
|
||||
android:layout_height="@dimen/dp_110"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_25"
|
||||
android:layout_marginBottom="@dimen/dp_25"
|
||||
android:layout_marginStart="@dimen/dp_25"
|
||||
/>
|
||||
<!--标题展示故障策略-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmTitleNormal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivFmImageNormal"
|
||||
android:layout_marginTop="@dimen/dp_25"
|
||||
android:layout_marginStart="@dimen/dp_23"
|
||||
android:textColor="#FFFFFFFF"
|
||||
android:textSize="@dimen/sp_32"
|
||||
/>
|
||||
<!--时间-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmTimeNormal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvFmTitleNormal"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvFmTitleNormal"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
/>
|
||||
<!--展开折叠按钮-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmStatusSelect"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="展开"
|
||||
android:textColor="#FFFFFFFF"
|
||||
android:textSize="@dimen/sp_24"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_25"
|
||||
android:layout_marginEnd="@dimen/dp_25"
|
||||
android:background="@drawable/bg_msg_status_select"
|
||||
android:drawableStart="@drawable/icon_msg_open"
|
||||
android:drawablePadding="@dimen/dp_10"
|
||||
android:paddingStart="@dimen/dp_15"
|
||||
android:paddingEnd="@dimen/dp_15"
|
||||
android:paddingTop="@dimen/dp_5"
|
||||
android:paddingBottom="@dimen/dp_5"
|
||||
/>
|
||||
<!--建议操作-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmActionNormal"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvFmTimeNormal"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvFmTimeNormal"
|
||||
app:layout_constraintRight_toRightOf="@id/tvFmStatusSelect"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:layout_marginBottom="@dimen/dp_25"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:gravity="start"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:maxLines="1"
|
||||
android:ellipsize="end"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
/>
|
||||
<!--时间-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmTime"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@id/tvFmStatusSelect"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvFmStatusSelect"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvFmStatusSelect"
|
||||
android:layout_marginEnd="@dimen/dp_20"
|
||||
android:textColor="#80FFFFFF"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
/>
|
||||
<!--展开时图标-->
|
||||
<ImageView
|
||||
android:id="@+id/ivFmImageOpen"
|
||||
android:layout_width="@dimen/dp_44"
|
||||
android:layout_height="@dimen/dp_44"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:layout_marginStart="@dimen/dp_20"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
<!--标题文案为故障策略-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmTitleOpen"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@id/ivFmImageOpen"
|
||||
app:layout_constraintBottom_toBottomOf="@id/ivFmImageOpen"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivFmImageOpen"
|
||||
android:textColor="#FFFFFFFF"
|
||||
android:textSize="@dimen/sp_32"
|
||||
android:layout_marginStart="@dimen/dp_10"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
<!--发生时间-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmTimeOpen"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/ivFmImageOpen"
|
||||
app:layout_constraintLeft_toLeftOf="@id/ivFmImageOpen"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
<!--建议操作-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmActionOpen"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvFmTimeOpen"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvFmTimeOpen"
|
||||
app:layout_constraintRight_toRightOf="@id/tvFmStatusSelect"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
android:visibility="gone"
|
||||
android:gravity="start"
|
||||
/>
|
||||
<!--故障策略-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmFaultOpen"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvFmActionOpen"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvFmActionOpen"
|
||||
app:layout_constraintRight_toRightOf="@id/tvFmStatusSelect"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
android:visibility="gone"
|
||||
android:gravity="start"
|
||||
/>
|
||||
<!--故障原因-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmReasonOpen"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvFmFaultOpen"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvFmFaultOpen"
|
||||
app:layout_constraintRight_toRightOf="@id/tvFmStatusSelect"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
android:visibility="gone"
|
||||
android:gravity="start"
|
||||
/>
|
||||
<!--后果-->
|
||||
<TextView
|
||||
android:id="@+id/tvFmResultOpen"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvFmReasonOpen"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvFmReasonOpen"
|
||||
app:layout_constraintRight_toRightOf="@id/tvFmStatusSelect"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
android:visibility="gone"
|
||||
android:gravity="start"
|
||||
/>
|
||||
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundConstraintLayout>
|
||||
@@ -138,10 +138,11 @@
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvReportTypeOpen"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvReportTimeOpen"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvReportTimeOpen"
|
||||
app:layout_constraintRight_toRightOf="@id/tvStatusSelect"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="28dp"
|
||||
android:lineSpacingMultiplier="1.2"
|
||||
|
||||
@@ -1,6 +1,67 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
<com.mogo.eagle.core.widget.RoundCanClickConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/clFmLayout"
|
||||
android:layout_width="@dimen/dp_804"
|
||||
android:layout_height="@dimen/dp_160"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#53000000"
|
||||
app:roundLayoutRadius="@dimen/dp_24"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="@dimen/dp_7"
|
||||
android:layout_marginBottom="@dimen/dp_7"
|
||||
>
|
||||
|
||||
</LinearLayout>
|
||||
<ImageView
|
||||
android:id="@+id/ivBubbleFmImage"
|
||||
android:layout_width="@dimen/dp_110"
|
||||
android:layout_height="@dimen/dp_110"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginStart="@dimen/dp_25"
|
||||
android:src="@drawable/icon_fm_stop_normal"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvBubbleFmFault"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivBubbleFmImage"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvBubbleFmFaultAction"
|
||||
android:layout_marginStart="@dimen/dp_25"
|
||||
android:textColor="#FFFFFFFF"
|
||||
android:textSize="@dimen/sp_32"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvBubbleFmFaultAction"
|
||||
android:layout_width="@dimen/dp_0"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvBubbleFmFault"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvBubbleFmFault"
|
||||
app:layout_constraintRight_toRightOf="@id/tvBubbleFmTime"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_6"
|
||||
android:textColor="#B3FFFFFF"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:maxLines="2"
|
||||
android:ellipsize="end"
|
||||
android:gravity="start"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvBubbleFmTime"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@id/tvBubbleFmFault"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvBubbleFmFault"
|
||||
android:layout_marginEnd="@dimen/dp_25"
|
||||
android:textColor="#80FFFFFF"
|
||||
android:textSize="@dimen/sp_24"
|
||||
/>
|
||||
|
||||
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundCanClickConstraintLayout>
|
||||