luobisheng
2022-12-08 0b0ce5c2bd14c1ff390dc7750ac5fd473e0b8c55
src/views/intelligentPatrol/studyJudge/index.vue
@@ -1,7 +1,7 @@
<template>
  <div class="study-judge">
    <div class="study-judge-header">
      <span>您有{{ eventList.length }}条待审核报警信息,今日立案0条,再学习{{ countData.review }}条</span>
      <span>您有{{ countData.register }}条待审核报警信息,今日立案{{ countData.review }}条,再学习{{ countData.study }}条</span>
    </div>
    <div class="study-judge-main">
      <div class="sjm-header">
@@ -39,10 +39,10 @@
                <span>{{ currentEvent.grade }}</span>
              </el-form-item>
              <el-form-item label="首次报警时间:">
                <span>{{ currentEvent.firstTime }}</span>
                <span>{{ currentEvent.alarmTime }}</span>
              </el-form-item>
              <el-form-item label="最近报警时间:">
                <span>{{ currentEvent.recentTime }}</span>
                <span>{{ currentEvent.currentAlarmTime }}</span>
              </el-form-item>
              <el-form-item label="持续时间:">
                <span>{{ currentEvent.conntinueTime }}</span>
@@ -99,6 +99,7 @@
import { FILE_ORIGINAL_URL } from "@/utils";
import { validateCarNum } from "@/utils/validate";
import MyDispatch from '@/components/dispatch';
import { formatDate } from "@/utils/date";
export default {
  components: { MyDispatch },
@@ -144,9 +145,10 @@
      }
    };
    return {
      eventList: [],
      countData: {
        review: 0
        study: 0,
        review: 0,
        register: 0
      },
      currentEvent: {},
      adviceList: [
@@ -208,10 +210,17 @@
    getInspectionData() {
      basecase.getInspectionData({ current: this.currentPage })
          .then(({ records }) => {
            this.eventList = records;
            this.currentEvent = this.eventList[0];
            this.currentEvent = records[0];
            if (this.currentEvent?.picData) {
              this.imageList = this.currentEvent.picData.split(',').map(item => `${FILE_ORIGINAL_URL}${item}`);
            }
            if (this.currentEvent?.alarmTime || this.currentEvent?.currentAlarmTime) {
              const { alarmTime, currentAlarmTime } = this.currentEvent;
              const continueAlarmTime = new Date().getTime() -
                  (currentAlarmTime ? new Date(currentAlarmTime).getTime() : new Date(alarmTime).getTime());
              const CONTINUE_DAY = continueAlarmTime / 1000 / 60 / 60 / 24;
              const CONTINUE_HOURS = (CONTINUE_DAY - parseInt(CONTINUE_DAY)) * 24;
              this.currentEvent.conntinueTime = `${parseInt(CONTINUE_DAY)}天${parseInt(CONTINUE_HOURS)}小时`;
            }
          })
          .catch(err => this.$message.error(err))
@@ -221,7 +230,7 @@
    handleConfirm(){
      this.$refs.currentEvent.validate((flag)=>{
        if(flag){
          this.eventInfoData.baseId = this.currentEvent.code;
          this.eventInfoData.baseId = this.currentEvent.baseId;
          // 调度
          if (this.eventInfoData.advice === 6) {