浏览代码

资源更换巡查轨迹接口

wang_xy 2 年之前
父节点
当前提交
87e6c1dd47
共有 2 个文件被更改,包括 3 次插入36 次删除
  1. 2 4
      src/api/leader.js
  2. 1 32
      src/views/leader.vue

+ 2 - 4
src/api/leader.js

@@ -9,11 +9,9 @@ export function getRy() {
 }
 
 // 获取左侧人员列表
-// export function getForestLeader(linJob,linType) {
-export function getForestLeader() {
+export function getForestLeader(linJob,linType) {
   return request({
-    // url: '/center-resources/VisuForestLeaderController/getForestLeader?linJob='+linJob+"&linType="+linType,
-    url: '/center-resources/VisuForestLeaderController/getPersonList',
+    url: '/center-resources/VisuForestLeaderController/getPersonList?linJob='+linJob+"&linType="+linType,
     method: 'get',
   })
 }

+ 1 - 32
src/views/leader.vue

@@ -68,7 +68,7 @@
           <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
             <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;" />
             <div class="this-title">
-              <span>巡任务</span>
+              <span>巡任务</span>
               <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;" />
             </div>
             <div class="i-list-con h-73">
@@ -138,7 +138,6 @@
 <script>
   import {
     getForestLeader,
-    getLeaderTrack,
     getPlanList,
     getRecordList,
     getPointList,
@@ -300,30 +299,6 @@
         })
         this.$refs.supermap.clearC()
       },
-      //点击左侧人员列表获取轨迹
-      getLeaderTrack(userId) {
-        this.getRemotelist();
-        this.listCurrentIndex1 = userId
-        let that = this
-        this.connectList = []
-        getLeaderTrack(userId).then(res => {
-          if (res.data != null && res.data.length > 0) {
-            for (let i = 0; i < res.data.length; i++) {
-              let latlng = {
-                lat: res.data[i].latitude,
-                lng: res.data[i].longitude
-              }
-              this.connectList.push(latlng)
-            }
-            setTimeout(() => {
-              that.$refs.supermap.clearC()
-              that.$refs.supermap.setConnectList(this.connectList, 'red')
-            }, 1000)
-          } else {
-            that.$refs.supermap.clearC()
-          }
-        })
-      },
       //点击右侧巡林计划获取 巡查记录
       getRecordList(id) {
         this.showNothing = false;
@@ -340,12 +315,6 @@
           this.setPointList(res);
         })
       },
-      //点击左侧人员获取人员的巡林计划列表
-      getRemotelist() {
-        getRemotelist().then(res => {
-          this.xunLinListOne = res.data;
-        })
-      },
       //点击巡查轨迹时段 巡查轨迹落点
       setPointList(res) {
         let that = this;