From 9f19494c76fac630de37311fbfc2d18d7f417a28 Mon Sep 17 00:00:00 2001
From: zengh <123456>
Date: Sun, 06 Jun 2021 21:24:44 +0800
Subject: [PATCH] 公安版本前端初版

---
 src/views/realTimePolice/real.vue           |   62 +--
 src/router/views/index.js                   |    2 
 src/views/policeTracking/policeTracking.vue | 1135 +++++++++++++++++++++-----------------------------------
 3 files changed, 442 insertions(+), 757 deletions(-)

diff --git a/src/router/views/index.js b/src/router/views/index.js
index 5be9b61..f5d9229 100644
--- a/src/router/views/index.js
+++ b/src/router/views/index.js
@@ -11,7 +11,7 @@
             i18n: 'dashboard'
         },
         component: () =>
-            import( /* webpackChunkName: "views" */ '@/views/home/home')
+            import( /* webpackChunkName: "views" */ '@/views/alarmManagement/alarmAnalysis')
     }]
 },
 
diff --git a/src/views/policeTracking/policeTracking.vue b/src/views/policeTracking/policeTracking.vue
index 619bfae..2e14938 100644
--- a/src/views/policeTracking/policeTracking.vue
+++ b/src/views/policeTracking/policeTracking.vue
@@ -40,62 +40,6 @@
             >
               <el-row>
                 <el-col span="12">
-                  <el-form-item label="报警人">
-                    <el-input
-                      disabled="true"
-                      v-model="form.galarmPeople"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-                <el-col span="12">
-                  <el-form-item label="报警人电话">
-                    <el-input
-                      disabled="true"
-                      v-model="form.phoneNumber"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-              </el-row>
-              <el-row>
-                <el-col span="12">
-                  <el-form-item label="主要负责人">
-                    <el-input
-                      disabled="true"
-                      v-model="form.oneContacts"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-                <el-col span="12">
-                  <el-form-item label="负责人电话">
-                    <el-input
-                      disabled="true"
-                      v-model="form.onePhone"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-              </el-row>
-              <el-row>
-                <el-col span="12">
-                  <el-form-item label="省份" class="cityClassParams">
-                    <avue-form :option="itemOption" v-model="form"></avue-form>
-                  </el-form-item>
-                </el-col>
-                <el-col span="12">
-                  <el-form-item label="事发地址">
-                    <el-input
-                      disabled="true"
-                      v-model="form.place"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-              </el-row>
-              <el-row>
-                <el-col span="12">
                   <el-form-item label="警情类型">
                     <el-input
                       disabled="true"
@@ -105,37 +49,6 @@
                   </el-form-item>
                 </el-col>
                 <el-col span="12">
-                  <el-form-item label="设备编号">
-                    <el-input
-                      disabled="true"
-                      v-model="form.deviceNumber"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-              </el-row>
-              <el-row>
-                <el-col span="12">
-                  <el-form-item label="接警人">
-                    <el-input
-                      disabled="true"
-                      v-model="form.alarmPeople"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-                <el-col span="12">
-                  <el-form-item label="报警内容">
-                    <el-input
-                      disabled="true"
-                      v-model="form.content"
-                      autocomplete="off"
-                    ></el-input>
-                  </el-form-item>
-                </el-col>
-              </el-row>
-              <el-row>
-                <el-col span="12">
                   <el-form-item label="报警时间">
                     <el-input
                       disabled="true"
@@ -144,173 +57,52 @@
                     ></el-input>
                   </el-form-item>
                 </el-col>
-                <el-col span="12">
-                  <el-form-item label="历史视频">
-                    <el-button type="primary" @click.stop="oldOpenVideo"
-                      >视频播放
-                    </el-button>
-                  </el-form-item>
-                </el-col>
               </el-row>
               <el-row>
-                <el-col span="12">
+                <el-col span="24">
                   <el-form-item label="备注">
                     <el-input
-                      :disabled="form.securityArr.length > 0"
                       v-model="form.bz"
                       autocomplete="off"
                     ></el-input>
                   </el-form-item>
                 </el-col>
               </el-row>
+              <el-row>
+                <el-col span="12">
+                  <el-form-item label="事发地址">
+                    <el-input
+                      v-model="form.place"
+                      autocomplete="off"
+                    ></el-input>
+                  </el-form-item>
+                </el-col>
+                <el-col span="12">
+                  <el-form-item label="省份" class="cityClassParams">
+                    <avue-form :option="itemOption" v-model="form"></avue-form>
+                  </el-form-item>
+                </el-col>
+              </el-row>
+              <el-row>
+                <el-col span="12">
+                  <avue-form :option="securityArritem" v-model="form"></avue-form>
+                </el-col>
+                <el-col span="12">
+                  <el-form-item label="派发人">
+                    <el-input
+                      disabled="true"
+                      v-model="form.alarmPeople"
+                      autocomplete="off"
+                    ></el-input>
+                  </el-form-item>
+                </el-col>
+              </el-row>
             </el-form>
-          </el-card>
 
-          <div
-            style="margin-top: 20px"
-            role="tab"
-            aria-expanded="true"
-            aria-controls="el-collapse-content-823"
-            aria-describedby="el-collapse-content-823"
-          >
-            <div
-              role="button"
-              tabindex="0"
-              class="el-collapse-item__header focusing is-active"
-            >
-              <div
-                class="avue-group__header avue-group"
-                style="position: relative"
-              >
-                <i class="el-icon-document avue-group__icon"></i>
-                <h1 class="avue-group__title">人员信息</h1>
-                <el-button
-                  @click="
-                    onSubmit('通知' + ensureNames, ensureId), (flag = false)
-                  "
-                  size="small"
-                  style="position: absolute; right: 0"
-                  :disabled="form.securityArr.length > 0"
-                  :type="form.securityArr.length > 0 ? 'info' : 'danger'"
-                  >通 知</el-button
-                >
-              </div>
+            <div class="grid-content bg-purple-light" style="text-align: center">
+              <el-button @click="onSubmit()" type="primary">派发</el-button>
             </div>
-          </div>
 
-          <el-card>
-            <el-table
-              ref="multipleTable"
-              :data="tableData"
-              tooltip-effect="dark"
-              style="width: 100%"
-              @selection-change="handleSelectionChange"
-              max-height="240"
-            >
-              <el-table-column
-                v-if="!(form.securityArr.length > 0)"
-                type="selection"
-                width="55"
-                align="center"
-              >
-              </el-table-column>
-
-              <el-table-column
-                prop="ind"
-                label="序号"
-                width="60"
-                align="center"
-              >
-              </el-table-column>
-              <el-table-column
-                prop="name"
-                label="姓名"
-                width="100"
-                align="center"
-              >
-              </el-table-column>
-              <el-table-column
-                prop="phone"
-                label="联系电话"
-                width="120"
-                align="center"
-              >
-              </el-table-column>
-              <el-table-column
-                prop="online_status"
-                label="在线状态"
-                width="80"
-                align="center"
-              >
-              </el-table-column>
-              <el-table-column
-                prop="tenantName"
-                label="所属部门"
-                align="center"
-              >
-              </el-table-column>
-
-              <el-table-column
-                prop="status"
-                label="通知状态"
-                width="120"
-                align="center"
-              >
-              </el-table-column>
-            </el-table>
-          </el-card>
-
-          <div
-            style="margin-top: 20px"
-            role="tab"
-            aria-expanded="true"
-            aria-controls="el-collapse-content-823"
-            aria-describedby="el-collapse-content-823"
-          >
-            <div
-              role="button"
-              tabindex="0"
-              class="el-collapse-item__header focusing is-active"
-            >
-              <div class="avue-group__header avue-group">
-                <i class="el-icon-document avue-group__icon"></i>
-                <h1 class="avue-group__title">接警信息</h1>
-              </div>
-            </div>
-          </div>
-
-          <el-card class="receiving-alarm-box">
-            <div v-for="(item, index) in receivingList" :key="index">
-              {{ item.zctime + " " + item.sname + " " + item.zc }}
-            </div>
-          </el-card>
-
-          <div
-            style="margin-top: 20px"
-            role="tab"
-            aria-expanded="true"
-            aria-controls="el-collapse-content-823"
-            aria-describedby="el-collapse-content-823"
-          >
-            <div
-              role="button"
-              tabindex="0"
-              class="el-collapse-item__header focusing is-active"
-            >
-              <div class="avue-group__header avue-group">
-                <i class="el-icon-phone avue-group__icon"></i>
-                <h1 class="avue-group__title">对讲信息</h1>
-              </div>
-            </div>
-          </div>
-
-          <el-card class="audios-box">
-            <m-audio
-              :block="false"
-              v-for="(item, index) in audios"
-              :key="index"
-              :src="item.address"
-            ></m-audio>
           </el-card>
 
           <div
@@ -508,511 +300,424 @@
 </template>
 
 <script>
-import axios from "axios";
-import { getList, getclient } from "@/api/real/real";
-export default {
-  inject: ["reload"],
-  data() {
-    return {
-      flag: true,
-      selectOptions: [],
-      receivingList: [],
-      security: {},
-      imgSrc: [],
-      srcList: [],
-      form: {},
-      itemOption: {
-        menuBtn: false,
-        column: [
-          {
-            disabled: true,
-            row: false,
-            prop: "province",
-            type: "select",
-            placeholder: "省份",
-            props: {
-              label: "name",
-              value: "code",
-            },
-            cascaderItem: ["city", "district"],
-            dicUrl: "/api/blade-system/region/select",
-            span: 1,
-            labelWidth: "0",
-            className: "cityClassSelect",
-          },
-          {
-            disabled: true,
-            row: false,
-            prop: "city",
-            type: "select",
-            placeholder: "地市",
-            props: {
-              label: "name",
-              value: "code",
-            },
-            dicUrl: "/api/blade-system/region/select?code={{key}}",
-            span: 1,
-            labelWidth: "0",
-            className: "cityClassSelect",
-          },
-          {
-            disabled: true,
-            row: false,
-            prop: "district",
-            type: "select",
-            placeholder: "区县",
-            props: {
-              label: "name",
-              value: "code",
-            },
-            dicUrl: "/api/blade-system/region/select?code={{key}}",
-            span: 1,
-            labelWidth: "0",
-            className: "cityClassSelect",
-          },
-        ],
-      },
-      tableData: [],
-      multipleSelection: [],
-      ensureNames: "",
-      ensureId: "",
-      baseUrl: "",
-      oldVideoSatart: false,
-      vaddress: null,
-      audios: [],
-      feedbackVideo: "",
-    };
-  },
-  created() {
-    this.form = this.$route.query;
-    if (
-      !(
-        this.form.securityArr &&
-        this.form.securityArr != null &&
-        this.form.securityArr != undefined &&
-        this.form.securityArr.length > 0
-      )
-    ) {
-      this.form.securityArr = [];
-    }
-    this.updatedPageData();
-    this.vaddress = this.form.vaddress;
-    this.getReceivingAlarm();
-    this.baseUrl = `/map/index.html?ISinit=1&openid=AlertSecurity&id=${this.form.id}&jd=${this.form.jd}&wd=${this.form.wd}&pid=${this.form.deptId}&deptId=${this.form.deptId}&oneId=${this.form.oneId}`;
-  },
-  mounted() {
-    this.getAudios();
-    this.getImgAndVideo();
-    this.$refs.mapDiv.onload = () => {
-      window.frames[1].init("AlertSecurity", {
-        x: this.form.jd,
-        y: this.form.wd,
-      });
-    };
-  },
-  updated() {
-    var arr = [];
-    this.tableData.forEach((item) => {
-      if (item.id == this.form.oneId) {
-        arr.push(item);
-      }
-    });
+  import axios from "axios";
+  import {getList, getclient} from "@/api/real/real";
+  import {update} from "@/api/real/real";
 
-    if (this.form.jtype != 2) {
-      this.toggleSelection(arr);
-    }
-  },
-  methods: {
-    getDate() {
-      // 当前时间
-      var timestamp = Date.parse(new Date());
-      var serverDate = new Date(timestamp);
-
-      // 本周周一的时间
-      var mondayTime =
-        timestamp - (serverDate.getDay() - 1) * 24 * 60 * 60 * 1000;
-      var mondayData = new Date(mondayTime);
-      //年
-      var mondayY = mondayData.getFullYear();
-      //月
-      var mondayM =
-        mondayData.getMonth() + 1 < 10
-          ? "0" + (mondayData.getMonth() + 1)
-          : mondayData.getMonth() + 1;
-      //日
-      var mondayD =
-        mondayData.getDate() < 10
-          ? "0" + mondayData.getDate()
-          : mondayData.getDate();
-      // 当前时间
-      var currentData = new Date(timestamp);
-      //年
-      var currentY = currentData.getFullYear();
-      //月
-      var currentM =
-        currentData.getMonth() + 1 < 10
-          ? "0" + (currentData.getMonth() + 1)
-          : currentData.getMonth() + 1;
-      //日
-      var currentD =
-        currentData.getDate() < 10
-          ? "0" + currentData.getDate()
-          : currentData.getDate();
-      //时
-      var currenH =
-        currentData.getHours() < 10
-          ? "0" + currentData.getHours()
-          : currentData.getHours();
-      //分
-      var currenM =
-        currentData.getMinutes() < 10
-          ? "0" + currentData.getMinutes()
-          : currentData.getMinutes();
-      //秒
-      var currenS =
-        currentData.getSeconds() < 10
-          ? "0" + currentData.getSeconds()
-          : currentData.getSeconds();
-
+  export default {
+    inject: ["reload"],
+    data() {
       return {
-        day: {
-          beginTime: currentY + "-" + currentM + "-" + currentD + " 00:00:00",
-          endTime:
-            currentY +
-            "-" +
-            currentM +
-            "-" +
-            currentD +
-            " " +
-            currenH +
-            ":" +
-            currenM +
-            ":00",
+        flag: true,
+        selectOptions: [],
+        receivingList: [],
+        security: {},
+        imgSrc: [],
+        srcList: [],
+        form: {},
+        itemOption: {
+          menuBtn: false,
+          column: [
+            {
+              disabled: true,
+              row: false,
+              prop: "province",
+              type: "select",
+              placeholder: "省份",
+              props: {
+                label: "name",
+                value: "code",
+              },
+              cascaderItem: ["city", "district"],
+              dicUrl: "/api/blade-system/region/select",
+              span: 1,
+              labelWidth: "0",
+              className: "cityClassSelect",
+            },
+            {
+              disabled: true,
+              row: false,
+              prop: "city",
+              type: "select",
+              placeholder: "地市",
+              props: {
+                label: "name",
+                value: "code",
+              },
+              dicUrl: "/api/blade-system/region/select?code={{key}}",
+              span: 1,
+              labelWidth: "0",
+              className: "cityClassSelect",
+            },
+            {
+              disabled: true,
+              row: false,
+              prop: "district",
+              type: "select",
+              placeholder: "区县",
+              props: {
+                label: "name",
+                value: "code",
+              },
+              dicUrl: "/api/blade-system/region/select?code={{key}}",
+              span: 1,
+              labelWidth: "0",
+              className: "cityClassSelect",
+            },
+          ],
+        }, securityArritem: {
+          menuBtn: false,
+          column: [
+            {
+              label: "处警员",
+              prop: "securityArr",
+              type: "tree",
+              multiple: true,
+              leafOnly: "",
+              span: 24,
+              dicUrl: "/api/blade-jfpts/catalogs/catalogs/getBigTree",
+              props: {
+                label: "title"
+              },
+              rules: [{
+                required: true,
+                message: "请选择处警员",
+                trigger: "blur"
+              }],
+            },
+          ],
         },
-        week: {
-          beginTime: mondayY + "-" + mondayM + "-" + mondayD + " 00:00:00",
-          endTime:
-            currentY +
-            "-" +
-            currentM +
-            "-" +
-            currentD +
-            " " +
-            currenH +
-            ":" +
-            currenM +
-            ":00",
-        },
-        month: {
-          beginTime: mondayY + "-" + mondayM + "-01 00:00:00",
-          endTime:
-            currentY +
-            "-" +
-            currentM +
-            "-" +
-            currentD +
-            " " +
-            currenH +
-            ":" +
-            currenM +
-            ":00",
-        },
-        current:
-          currentY +
-          "-" +
-          currentM +
-          "-" +
-          currentD +
-          " " +
-          currenH +
-          ":" +
-          currenM +
-          ":" +
-          currenS,
+        tableData: [],
+        multipleSelection: [],
+        ensureNames: "",
+        ensureId: "",
+        baseUrl: "",
+        oldVideoSatart: false,
+        vaddress: null,
+        audios: [],
+        feedbackVideo: "",
       };
     },
-    onSubmit(zc, ensureId) {
-      var that = this;
-      var subData = {
-        jid: this.form.id,
-        jtype: 1,
-        rid: this.form.alarmId,
-        bz: this.form.bz,
-        snumber: this.form.alarmId,
-        sname: this.form.alarmPeople,
-        deviceNumber: this.form.deviceNumber,
-        zc: zc,
-        zctime: this.getDate().current,
-      };
-      if (ensureId && ensureId != "") {
-        subData.securityArr = ensureId;
+    created() {
+      this.form = this.$route.query;
+      if (
+        !(
+          this.form.securityArr &&
+          this.form.securityArr != null &&
+          this.form.securityArr != undefined &&
+          this.form.securityArr.length > 0
+        )
+      ) {
+        this.form.securityArr = [];
       }
-      axios
-        .post(
-          "/api/blade-jfpts/alarm/alarm/updateJtype",
-          {},
-          {
-            params: subData,
-          }
-        )
-        .then(function (res) {
-          that.getReceivingAlarm();
-
-          that.updatedPageData();
-        });
+      this.updatedPageData();
+      this.vaddress = this.form.vaddress;
+      this.getReceivingAlarm();
+      this.baseUrl = `/map/index.html?ISinit=1&openid=AlertSecurity&id=${this.form.id}&jd=${this.form.jd}&wd=${this.form.wd}&pid=${this.form.deptId}&deptId=${this.form.deptId}&oneId=${this.form.oneId}`;
     },
-
-    getReceivingAlarm() {
-      axios
-        .get(`/api/blade-jfpts/operation/list?jid=${this.form.id}`)
-        .then((res) => {
-          this.receivingList = res.data.data.records;
+    mounted() {
+      this.getAudios();
+      this.getImgAndVideo();
+      this.$refs.mapDiv.onload = () => {
+        window.frames[1].init("AlertSecurity", {
+          x: this.form.jd,
+          y: this.form.wd,
         });
+      };
     },
+    updated() {
+      var arr = [];
+      this.tableData.forEach((item) => {
+        if (item.id == this.form.oneId) {
+          arr.push(item);
+        }
+      });
 
-    getList() {
-      var that = this;
-      var deptid = that.form.deptId.slice(0, 19); //报错deptId格式不对liu.2021.5.7
-      axios
-        .get(
-          `/api/blade-user/pages?current=1&size=9999&work_status=&deptId=${deptid}`
-        )
-        .then(function (res) {
-          that.tableData = [];
-          var i = 0;
-          console.log(that.form, 89);
-          if (
-            that.form.securityArr &&
-            that.form.securityArr != null &&
-            that.form.securityArr != undefined &&
-            that.form.securityArr.length > 0
-          ) {
-            res.data.data.records.forEach((item) => {
-              if (item.id == that.form.securityId) {
-                that.tableData.push({
-                  id: item.id,
-                  ind: (i += 1),
-                  name: item.name,
-                  phone: item.phone,
-                  online_status: item.online_status == 1 ? "在线" : "掉线",
-                  status: "已接警",
-                  tenantName: item.tenantName,
-                });
-              }
-            });
+      if (this.form.jtype != 2) {
+        this.toggleSelection(arr);
+      }
+    },
+    methods: {
+      getDate() {
+        // 当前时间
+        var timestamp = Date.parse(new Date());
+        var serverDate = new Date(timestamp);
 
-            res.data.data.records.forEach((item) => {
-              if (
-                item.roleName == "处警员" &&
-                that.form.securityArr.indexOf(item.id) != -1 &&
-                item.id != that.form.securityId
-              ) {
-                that.tableData.push({
-                  id: item.id,
-                  ind: (i += 1),
-                  name: item.name,
-                  phone: item.phone,
-                  online_status: item.online_status == 1 ? "在线" : "掉线",
-                  status: "已通知",
-                  tenantName: item.tenantName,
-                });
-              } else if (
-                item.roleName == "处警员" &&
-                that.form.securityArr.indexOf(item.id) == -1 &&
-                item.id != that.form.securityId
-              ) {
-                that.tableData.push({
-                  id: item.id,
-                  ind: (i += 1),
-                  name: item.name,
-                  phone: item.phone,
-                  online_status: item.online_status == 1 ? "在线" : "掉线",
-                  status: "未通知",
-                  tenantName: item.tenantName,
-                });
-              }
-            });
+        // 本周周一的时间
+        var mondayTime =
+          timestamp - (serverDate.getDay() - 1) * 24 * 60 * 60 * 1000;
+        var mondayData = new Date(mondayTime);
+        //年
+        var mondayY = mondayData.getFullYear();
+        //月
+        var mondayM =
+          mondayData.getMonth() + 1 < 10
+            ? "0" + (mondayData.getMonth() + 1)
+            : mondayData.getMonth() + 1;
+        //日
+        var mondayD =
+          mondayData.getDate() < 10
+            ? "0" + mondayData.getDate()
+            : mondayData.getDate();
+        // 当前时间
+        var currentData = new Date(timestamp);
+        //年
+        var currentY = currentData.getFullYear();
+        //月
+        var currentM =
+          currentData.getMonth() + 1 < 10
+            ? "0" + (currentData.getMonth() + 1)
+            : currentData.getMonth() + 1;
+        //日
+        var currentD =
+          currentData.getDate() < 10
+            ? "0" + currentData.getDate()
+            : currentData.getDate();
+        //时
+        var currenH =
+          currentData.getHours() < 10
+            ? "0" + currentData.getHours()
+            : currentData.getHours();
+        //分
+        var currenM =
+          currentData.getMinutes() < 10
+            ? "0" + currentData.getMinutes()
+            : currentData.getMinutes();
+        //秒
+        var currenS =
+          currentData.getSeconds() < 10
+            ? "0" + currentData.getSeconds()
+            : currentData.getSeconds();
 
-            that.tableData.forEach((item) => {
-              if (item.id == that.form.oneId) {
-                item.status += "(负责人)";
-              }
-            });
+        return {
+          day: {
+            beginTime: currentY + "-" + currentM + "-" + currentD + " 00:00:00",
+            endTime:
+              currentY +
+              "-" +
+              currentM +
+              "-" +
+              currentD +
+              " " +
+              currenH +
+              ":" +
+              currenM +
+              ":00",
+          },
+          week: {
+            beginTime: mondayY + "-" + mondayM + "-" + mondayD + " 00:00:00",
+            endTime:
+              currentY +
+              "-" +
+              currentM +
+              "-" +
+              currentD +
+              " " +
+              currenH +
+              ":" +
+              currenM +
+              ":00",
+          },
+          month: {
+            beginTime: mondayY + "-" + mondayM + "-01 00:00:00",
+            endTime:
+              currentY +
+              "-" +
+              currentM +
+              "-" +
+              currentD +
+              " " +
+              currenH +
+              ":" +
+              currenM +
+              ":00",
+          },
+          current:
+            currentY +
+            "-" +
+            currentM +
+            "-" +
+            currentD +
+            " " +
+            currenH +
+            ":" +
+            currenM +
+            ":" +
+            currenS,
+        };
+      },
+      onSubmit() {
+        var that = this;
+        axios({
+          url: '/api/blade-jfpts/alarm/alarm/submit',
+          method: 'post',
+          data: that.form
+        }).then((resdata) => {
+          that.$message({
+            message: '派遣完成',
+            type: 'success'
+          });
+        });
+      },
+
+      getReceivingAlarm() {
+        axios
+          .get(`/api/blade-jfpts/operation/list?jid=${this.form.id}`)
+          .then((res) => {
+            this.receivingList = res.data.data.records;
+          });
+      },
+
+      getList() {
+        var that = this;
+      },
+
+      handleSelectionChange(val) {
+        this.ensureNames = "";
+        this.ensureId = "";
+        val.forEach((item, index) => {
+          this.ensureId += item.id;
+          this.ensureId += ",";
+          if (index == val.length - 1) {
+            this.ensureNames += item.name;
+            this.ensureNames += "。";
           } else {
-            res.data.data.records.forEach((item) => {
-              if (item.id == that.form.oneId) {
-                that.tableData.push({
-                  id: item.id,
-                  ind: (i += 1),
-                  name: item.name,
-                  phone: item.phone,
-                  online_status: item.online_status == 1 ? "在线" : "掉线",
-                  status: "未通知(负责人)",
-                  tenantName: item.tenantName,
-                });
-              }
-            });
-
-            res.data.data.records.forEach((item) => {
-              if (item.roleName == "处警员" && item.id != that.form.oneId) {
-                that.tableData.push({
-                  id: item.id,
-                  ind: (i += 1),
-                  name: item.name,
-                  phone: item.phone,
-                  online_status: item.online_status == 1 ? "在线" : "掉线",
-                  status: "未通知",
-                  tenantName: item.tenantName,
-                });
-              }
-            });
+            this.ensureNames += item.name;
+            this.ensureNames += "、";
           }
         });
-    },
 
-    handleSelectionChange(val) {
-      this.ensureNames = "";
-      this.ensureId = "";
-      val.forEach((item, index) => {
-        this.ensureId += item.id;
-        this.ensureId += ",";
-        if (index == val.length - 1) {
-          this.ensureNames += item.name;
-          this.ensureNames += "。";
+        this.multipleSelection = val;
+      },
+
+      toggleSelection(rows) {
+        if (rows) {
+          rows.forEach((row) => {
+            this.$refs.multipleTable.toggleRowSelection(row);
+          });
         } else {
-          this.ensureNames += item.name;
-          this.ensureNames += "、";
+          this.$refs.multipleTable.clearSelection();
         }
-      });
+      },
 
-      this.multipleSelection = val;
-    },
-
-    toggleSelection(rows) {
-      if (rows) {
-        rows.forEach((row) => {
-          this.$refs.multipleTable.toggleRowSelection(row);
+      getAudios() {
+        axios({
+          method: "get",
+          url: "/api/blade-jfpts/avideo/list",
+          params: {
+            jid: this.form.id,
+          },
+        }).then((resdata) => {
+          if (resdata.data.data.records.length > 0)
+            this.audios = resdata.data.data.records;
         });
-      } else {
-        this.$refs.multipleTable.clearSelection();
-      }
-    },
-
-    getAudios() {
-      axios({
-        method: "get",
-        url: "/api/blade-jfpts/avideo/list",
-        params: {
-          jid: this.form.id,
-        },
-      }).then((resdata) => {
-        if (resdata.data.data.records.length > 0)
-          this.audios = resdata.data.data.records;
-      });
-    },
-
-    getImgAndVideo() {
-      axios({
-        method: "post",
-        url: "/api/blade-jfpts/feedback/feedback/selectFeedEdit",
-        params: {
-          jid: this.form.id,
-        },
-      }).then((resdata) => {
-        if (resdata.data.data.length > 0) {
-          if (resdata.data.data[0].List.length > 0)
-            this.security = resdata.data.data[0].List[0];
-          if (resdata.data.data[0].tp.length > 0) {
-            this.imgSrc = resdata.data.data[0].tp;
-            this.srcList = resdata.data.data[0].tp;
+      },
+      getImgAndVideo() {
+        axios({
+          method: "post",
+          url: "/api/blade-jfpts/feedback/feedback/selectFeedEdit",
+          params: {
+            jid: this.form.id,
+          },
+        }).then((resdata) => {
+          if (resdata.data.data.length > 0) {
+            if (resdata.data.data[0].List.length > 0)
+              this.security = resdata.data.data[0].List[0];
+            if (resdata.data.data[0].tp.length > 0) {
+              this.imgSrc = resdata.data.data[0].tp;
+              this.srcList = resdata.data.data[0].tp;
+            }
+            if (resdata.data.data[0].sp.length > 0) {
+              this.feedbackVideo = resdata.data.data[0].sp[0];
+            }
           }
-          if (resdata.data.data[0].sp.length > 0) {
-            this.feedbackVideo = resdata.data.data[0].sp[0];
+        });
+      },
+
+      oldOpenVideo() {
+        getclient(this.form.id).then((res) => {
+          if (res.data.data.vaddress != "") {
+            this.vaddress = res.data.data.vaddress;
           }
-        }
-      });
-    },
+          this.oldVideoSatart = true;
+        });
+      },
 
-    oldOpenVideo() {
-      getclient(this.form.id).then((res) => {
-        if (res.data.data.vaddress != "") {
-          this.vaddress = res.data.data.vaddress;
-        }
-        this.oldVideoSatart = true;
-      });
+      updatedPageData() {
+        var that = this;
+        axios({
+          method: "get",
+          url: "/api/blade-jfpts/alarm/alarm/page",
+          params: {
+            id: that.form.id,
+          },
+        }).then(function (res) {
+          that.form = res.data.data.records[0];
+          if (
+            !(
+              that.form.securityArr &&
+              that.form.securityArr != null &&
+              that.form.securityArr != undefined &&
+              that.form.securityArr.length > 0
+            )
+          ) {
+            that.form.securityArr = [];
+          }
+          that.getList(); //报错deptId格式不对liu.2021.5.7
+        });
+      },
     },
-
-    updatedPageData() {
-      var that = this;
-      axios({
-        method: "get",
-        url: "/api/blade-jfpts/alarm/alarm/page",
-        params: {
-          id: that.form.id,
-        },
-      }).then(function (res) {
-        that.form = res.data.data.records[0];
-        if (
-          !(
-            that.form.securityArr &&
-            that.form.securityArr != null &&
-            that.form.securityArr != undefined &&
-            that.form.securityArr.length > 0
-          )
-        ) {
-          that.form.securityArr = [];
-        }
-        that.getList(); //报错deptId格式不对liu.2021.5.7
-      });
-    },
-  },
-};
+  };
 </script>
 
 <style scoped lang="scss">
-.el-col {
-  height: calc(100% - 5px);
-}
-
-.trackClass {
-  height: 100%;
-  overflow: auto;
-  overflow-x: hidden;
-}
-
-.receiving-alarm-box {
-  line-height: 32px !important;
-  height: 200px;
-  overflow-y: auto;
-  .el-card__body {
-    padding: 0 10px !important;
+  .el-col {
+    height: calc(100% - 5px);
   }
-}
 
-.audios-box,
-.scene-image-box {
-  line-height: 32px !important;
-  height: auto;
-  max-height: 200px;
-  overflow-y: auto;
-  .el-card__body {
-    display: flex;
-    padding: 0 10px !important;
-    flex-wrap: wrap;
-    justify-content: center;
-    align-items: center;
-    .x-audio-wrap.inline {
-      margin: 10px;
-    }
-    .el-image {
-      margin: 10px;
-      width: 160px;
-      height: 80px;
+  .trackClass {
+    height: 100%;
+    overflow: auto;
+    overflow-x: hidden;
+  }
+
+  .receiving-alarm-box {
+    line-height: 32px !important;
+    height: 200px;
+    overflow-y: auto;
+
+    .el-card__body {
+      padding: 0 10px !important;
     }
   }
-}
 
-#old_video::-webkit-media-controls-timeline {
-  display: block;
-}
+  .audios-box,
+  .scene-image-box {
+    line-height: 32px !important;
+    height: auto;
+    max-height: 200px;
+    overflow-y: auto;
+
+    .el-card__body {
+      display: flex;
+      padding: 0 10px !important;
+      flex-wrap: wrap;
+      justify-content: center;
+      align-items: center;
+
+      .x-audio-wrap.inline {
+        margin: 10px;
+      }
+
+      .el-image {
+        margin: 10px;
+        width: 160px;
+        height: 80px;
+      }
+    }
+  }
+
+  #old_video::-webkit-media-controls-timeline {
+    display: block;
+  }
 </style>
diff --git a/src/views/realTimePolice/real.vue b/src/views/realTimePolice/real.vue
index 0602819..d5cb4a3 100644
--- a/src/views/realTimePolice/real.vue
+++ b/src/views/realTimePolice/real.vue
@@ -86,7 +86,7 @@
       <template slot-scope="{ row }" slot="jtype">
         <el-tag
         >{{
-          row.jtype == "0" ? "未处理" : row.jtype == "1" ? "处理中" : "已处理"
+          row.jtype == "0" || row.jtype == "" ? "未处理" : row.jtype == "1" ? "处理中" : "已处理"
           }}
         </el-tag>
       </template>
@@ -98,25 +98,16 @@
         </el-tag>
       </template>
 
-<!--      <template slot-scope="{ type, size, row }" slot="menu">-->
-
-<!--        <el-button-->
-<!--          v-if="row.jtype == 0 || row.jtype == ''"-->
-<!--          icon="el-icon-edit"-->
-<!--          :size="size"-->
-<!--          :type="type"-->
-<!--          @click.stop="handleManage(row)"-->
-<!--        >核实-->
-<!--        </el-button>-->
-<!--        <el-button-->
-<!--          v-if="row.jtype != 0 && row.jtype != ''"-->
-<!--          icon="el-icon-s-order"-->
-<!--          :size="size"-->
-<!--          :type="type"-->
-<!--          @click.stop="PoliceTracking(row)"-->
-<!--        >追踪-->
-<!--        </el-button>-->
-<!--      </template>-->
+      <template slot-scope="{ type, size, row }" slot="menu">
+        <el-button
+          v-if="row.jtype == 0 || row.jtype == 0 || row.jtype == ''"
+          icon="el-icon-s-order"
+          :size="size"
+          :type="type"
+          @click.stop="PoliceTracking(row)"
+        >派发
+        </el-button>
+      </template>
     </avue-crud>
     <real-popup ref="realPopupView"></real-popup>
     <el-drawer title="电子地图" append-to-body="true" :visible.sync="showMap">
@@ -220,16 +211,10 @@
                   trigger: "blur",
                 },
               ],
-            },
-            {
-              label: "报警人",
-              prop: "galarmPeople",
-              width: 90,
-            },
-            {
-              label: "报警人电话",
-              prop: "phoneNumber",
-              width: 130,
+            },{
+              label: "备注",
+              prop: "bz",
+              span:24,
             },
             {
               label: "地址",
@@ -285,7 +270,6 @@
               dicUrl: "/api/blade-system/region/select",
               span: 6,
               className: "cityreal1",
-              hide: true,
               addDisplay: true,
               editDisplay: true,
               viewDisplay: true,
@@ -307,7 +291,6 @@
               span: 3,
               labelWidth: "0",
               className: "cityreal2",
-              hide: true,
               addDisplay: true,
               editDisplay: true,
               viewDisplay: true,
@@ -329,17 +312,9 @@
               span: 3,
               labelWidth: "0",
               className: "cityreal3",
-              hide: true,
               addDisplay: true,
               editDisplay: true,
               viewDisplay: true,
-            },
-            {
-              label: "设备编号",
-              search: true,
-              searchSpan: 3,
-              width: 130,
-              prop: "deviceNumber",
             },
             {
               label: "警情状态",
@@ -369,6 +344,8 @@
               label: "派发人",
               prop: "alarmPeople",
               width: 90,
+              addDisplay: false,
+              editDisplay: false,
             },
             {
               label: "处警员",
@@ -468,12 +445,15 @@
     },
     methods: {
       rowSave(row, done, loading) {
-        debugger;
         var security = "";
         row.securityArr.forEach((item) => {
           security = security + item + ",";
         });
         row.securityArr = security.substring(0, security.length - 1);
+        var userId = JSON.parse(
+          window.localStorage.getItem("警群联控后台管理系统-userInfo")
+        ).content.real_name;
+        row.alarmPeople = userId;
         add(row).then(
           () => {
             this.onLoad(this.page);

--
Gitblit v1.9.3