保安监管系统-验收版本
Administrator
2021-09-15 6150cb98194814c285e8f72d7e8c11bbd8b9a121
src/views/commandQuery/taskDistribution.vue
@@ -1,13 +1,14 @@
/*
 * @Author: Morpheus
 * @Date: 2021-07-07 17:30:05
 * @Last Modified by: Morpheus
 * @Last Modified time: 2021-08-12 21:00:27
 * @Last Modified by: liu
 * @Last Modified time: 2021-09-15 16:53:45
 * menu-name 监管信息
 */
<template>
    <basic-container>
        <avue-crud :option="option"
  <basic-container class="fontcolorfff">
    <avue-crud
      :option="option"
                   :table-loading="loading"
                   :data="data"
                   :page.sync="page"
@@ -23,48 +24,61 @@
                   @current-change="currentChange"
                   @size-change="sizeChange"
                   @refresh-change="refreshChange"
                   @on-load="onLoad">
            <template slot-scope="{ type, size, row }"
                      slot="menu">
                <el-button icon="el-icon-location-outline"
      @on-load="onLoad"
    >
      <template slot-scope="{ type, size, row }" slot="menu">
        <el-button
          icon="el-icon-location-outline"
                           :size="size"
                           :type="type"
                           @click.stop="seeLocation(row)">位置查看</el-button>
                <el-button icon="el-icon-place"
          @click.stop="seeLocation(row)"
          >位置查看</el-button
        >
        <el-button
          icon="el-icon-place"
                           :size="size"
                           :type="type"
                           @click.stop="seeTrack(row)">轨迹查看
          @click.stop="seeTrack(row)"
          >轨迹查看
                </el-button>
            </template>
        </avue-crud>
        <el-dialog class="see-location"
    <el-dialog
      class="see-location"
                   title="位置查看"
                   :visible.sync="seeLocationFlag"
                   :modal-append-to-body="false"
                   width="width">
      width="width"
    >
      <!-- <div>
        基本信息
        <div><span>姓名:</span><span>123</span></div>
        <div><span>电话:</span><span>123</span></div>
        <div><span>所属公司:</span><span>123</span></div>
      </div> -->
            <Map ref="locationForm" />
        </el-dialog>
        <el-dialog class="see-track"
    <el-dialog
      class="see-track"
                   title="轨迹查看"
                   :visible.sync="seeTrackFlag"
                   :modal-append-to-body="false"
                   width="width">
      width="width"
    >
            <div class="search">
                选择时间:<el-date-picker v-model="trackTime"
        选择时间:<el-date-picker
          v-model="trackTime"
                                type="datetimerange"
                                range-separator="至"
                                start-placeholder="开始日期"
                                size="mini"
                                :editable="false"
                                end-placeholder="结束日期">
          end-placeholder="结束日期"
        >
                </el-date-picker>
                <el-button type="text"
                           @click="lookTrack">
                    查看轨迹
                </el-button>
        <el-button type="text" @click="lookTrack"> 查看轨迹 </el-button>
            </div>
            <Map ref="tarckForm" />
@@ -73,6 +87,7 @@
</template>
<script>
import { getListSecurity } from "@/api/system/user";
// import {
//   getList,
//   getDetail,
@@ -84,7 +99,10 @@
// import { datasing } from "./dataqualificationExamination";
// import { getList } from "@/api/qualificationExamination/qualificationExamination";
import { getLisperetaskDistribution } from "@/api/commandQuery/commandQuery";
import { getDirectiveLiveLocationVoList, getDirectiveLocusInfoList } from "@/api/map/people";
import {
  getDirectiveLiveLocationVoList,
  getDirectiveLocusInfoList,
} from "@/api/map/people";
import peoplePng from "@/assets/img/people.png";
export default {
@@ -226,6 +244,7 @@
            return ids.join(",");
        },
    },
  mounted() {},
    methods: {
        rowSave (row, done, loading) {
            adddata(row).then(
@@ -327,6 +346,17 @@
                // }
                console.log(this.data, "getLisperetaskDistribution");
                this.loading = false;
        //获取人员信息;
        // for (var k in this.data) {
        //   console.log(this.data[k].receiveDirectiveIds);
        // }
        //     var params = {
        //   id:
        // };
        // getListSecurity(1, 10, params).then((res) => {
        //   console.log(res.data.data, 5555555555);
        // });
                // this.selectionClear();
            });
        },
@@ -376,10 +406,12 @@
        },
        seeLocation (row) {
      this.seeLocationFlag = true;
            this.seeLocationFlag = true
            getDirectiveLiveLocationVoList({ type: 1, userIds: row.receiveDirectiveIds }).then((result) => {
      getDirectiveLiveLocationVoList({
        type: 1,
        userIds: row.receiveDirectiveIds,
      }).then((result) => {
                var res = result.data.data;
                if (JSON.stringify(res) != "[]") {
                    res.forEach((data)=>{
@@ -394,17 +426,16 @@
                            "peoplelayer",
                            "peopleAddlayer"
                        );
                    })
          });
                }
            });
        },
        seeTrack (row) {
            this.trackTime = [];
            this.rowData = '';
      this.rowData = "";
            this.rowData = row;
            this.seeTrackFlag = true
      this.seeTrackFlag = true;
        },
        lookTrack () {
@@ -461,7 +492,7 @@
                            this.$refs.tarckForm.addLines(arr);
                        }
                    })
          });
                }
            });
        },