[6.7.2]接管记录增加bag Id上报

This commit is contained in:
xuxinchao
2024-10-28 15:09:13 +08:00
parent b7d91c92a6
commit 89a0b5caae
11 changed files with 22 additions and 16 deletions

View File

@@ -29,7 +29,7 @@ object RecordManager {
takeOverRecordInfo.let {
val recordInfo = RecordInfo(it.faultStartTime,it.address,
it.level1Id,it.level1Name, it.level2Id,it.level2Name,
it.level3Id,it.level3Name,it.lineName,it.reportNote,it.reportStatus)
it.level3Id,it.level3Name,it.lineName,it.reportNote,it.reportStatus,it.bagId)
if (Thread.currentThread() == Looper.getMainLooper().thread){
scope.launch{
withContext(Dispatchers.IO){
@@ -62,7 +62,7 @@ object RecordManager {
takeOverRecordInfo.let{
val recordInfo = RecordInfo(it.faultStartTime,it.address,it.level1Id,
it.level1Name, it.level2Id,it.level2Name,it.level3Id,it.level3Name,
it.lineName,it.reportNote,it.reportStatus)
it.lineName,it.reportNote,it.reportStatus,it.bagId)
if (Thread.currentThread() == Looper.getMainLooper().thread){
scope.launch{
withContext(Dispatchers.IO){
@@ -95,7 +95,7 @@ object RecordManager {
takeOverRecordInfo.let{
val recordInfo = RecordInfo(it.faultStartTime,it.address,it.level1Id,
it.level1Name, it.level2Id,it.level2Name,it.level3Id,it.level3Name,
it.lineName,it.reportNote,it.reportStatus)
it.lineName,it.reportNote,it.reportStatus,it.bagId)
if (Thread.currentThread() == Looper.getMainLooper().thread){
scope.launch {
withContext(Dispatchers.IO) {

View File

@@ -44,7 +44,7 @@ class TakeOverRecordProvider: ITakeOverProvider {
recordInfoList.add(
TakeOverRecordInfo(it.faultStartTime,it.address,it.level1Id,
it.level2Id,it.level3Id,it.level1Name,it.level2Name,it.level3Name,
it.lineName,it.reportNote,it.reportStatus,false)
it.lineName,it.reportNote,it.reportStatus,false,it.bagId)
)
}
return recordInfoList

View File

@@ -41,5 +41,8 @@ data class RecordInfo(
var reportNote: String,
//上传状态 false:未上传,可编辑 true:已上传,不可编辑
@ColumnInfo
var reportStatus: Boolean
var reportStatus: Boolean,
//Bag包唯一标识 key
@ColumnInfo
var bagId: Long
)

View File

@@ -445,9 +445,8 @@ internal object BadCaseManager : LifecycleEventObserver, IMoGoAutopilotRecordLis
address,level1Id,level2Id,level3Id,
level1Name, level2Name, level3Name,
BadCaseConfig.lineName,reportNote,
reportStatus = false,
selectStatus = false
)
reportStatus = false, selectStatus = false,
recordPanel.key)
CallerTakeOverManager.insertRecord(activity,takeOverRecordInfo)
}

View File

@@ -386,8 +386,8 @@ class FaultReasonWindow constructor(activity: Activity) : View.OnTouchListener,
val padProblemInfo = PadProblemInfo(
address, faultCodeList, millis2String(workOrderOccurrenceTime), level1Id,
level2Id, level3Id, BadCaseConfig.lineName, note, reportType,
SharedPrefsMgr.getInstance().getString("och_account", "")
)
SharedPrefsMgr.getInstance().getString("och_account", ""),
0L)
padProblemList.add(padProblemInfo)
val padAddProblemReq =
PadAddProblemReq(padProblemList, AppConfigInfo.plateNumber)

View File

@@ -143,7 +143,7 @@ class ReportTypeWindow constructor(activity: Activity): IMoGoDevaToolsListener {
val padProblemList= ArrayList<PadProblemInfo>()
val padProblemInfo = PadProblemInfo(address,faultCodeList,millis2String(System.currentTimeMillis()),level1Id,
level2Id,level3Id,BadCaseConfig.lineName,"${level1Name}-${level2Name}-${level3Name}",reportType,
SharedPrefsMgr.getInstance().getString("och_account",""))
SharedPrefsMgr.getInstance().getString("och_account",""),0L)
padProblemList.add(padProblemInfo)
val padAddProblemReq = PadAddProblemReq(padProblemList, AppConfigInfo.plateNumber)
CallerDevaToolsManager.problemPadAdd(padAddProblemReq)

View File

@@ -140,7 +140,8 @@ class TakeOverRecordView @JvmOverloads constructor(
val padProblemInfo = PadProblemInfo(it.address, emptyList(),
millis2String(it.faultStartTime),it.level1Id,it.level2Id,it.level3Id,
it.lineName,reason,1,
SharedPrefsMgr.getInstance().getString("och_account",""))
SharedPrefsMgr.getInstance().getString("och_account",""),
it.bagId)
padProblemList.add(padProblemInfo)
}

View File

@@ -337,7 +337,7 @@ class FaultReasonView @JvmOverloads constructor(
val padProblemInfo = PadProblemInfo(
address, faultCodeList, millis2String(workOrderOccurrenceTime), level1Id,
level2Id, level3Id, BadCaseConfig.lineName, note, reportType,
SharedPrefsMgr.getInstance().getString("och_account", "")
SharedPrefsMgr.getInstance().getString("och_account", ""),0L
)
padProblemList.add(padProblemInfo)
val padAddProblemReq =

View File

@@ -102,7 +102,7 @@ class ReportTypeView @JvmOverloads constructor(
val padProblemList= ArrayList<PadProblemInfo>()
val padProblemInfo = PadProblemInfo(address,faultCodeList,millis2String(System.currentTimeMillis()),level1Id,
level2Id,level3Id,BadCaseConfig.lineName,"${level1Name}-${level2Name}-${level3Name}",reportType,
SharedPrefsMgr.getInstance().getString("och_account",""))
SharedPrefsMgr.getInstance().getString("och_account",""),0L)
padProblemList.add(padProblemInfo)
val padAddProblemReq = PadAddProblemReq(padProblemList, AppConfigInfo.plateNumber)
CallerDevaToolsManager.problemPadAdd(padAddProblemReq)