lizhanwei
2020-03-22 fad6626d6375cb9a2991e9e9e2cb5fdc0f3b7b74
app/src/main/java/safeluck/drive/evaluation/DB/exam_status/ExamStatusOutWorker.kt
@@ -108,17 +108,22 @@
        sendSignalConfigsToRemote(indexs)
        val data = Data.Builder().putInt(Constant.EXAM_STATUS_TYPE,examType).build()
        if (examType != safeluck.drive.evaluation.Constant.NONE_BEEN_START_EXAM) {
//        if (examType != safeluck.drive.evaluation.Constant.NONE_BEEN_START_EXAM) {
            try {
                val jsonObject = JSONObject()
                jsonObject.put("exam", 1)
                if (examType == safeluck.drive.evaluation.Constant.NONE_BEEN_START_EXAM) {
                    jsonObject.put("exam", 0)
                }else{
                    jsonObject.put("exam", 1)
                }
                jsonObject.put("type", examType)
                val examJson = jsonObject.toString()
                AYSdk.getInstance().sendCmd(safeluck.drive.evaluation.Constant.EXAM_STATUS, examJson)
            } catch (e: JSONException) {
                e.printStackTrace()
            }
        }
//        }
        return Result.success(data)
    }