Browse Source

代码更新 2/24

zhangyun 4 năm trước cách đây
mục cha
commit
72d21d220e

+ 2 - 1
minggao/src/page/commandCenter/superviseLog.vue

@@ -169,7 +169,7 @@ export default {
         data: this.qs.stringify({
           page: this.page, // 当前页码
           page_item: "20", //
-          monitor_user_id: "", // 监测人id
+          monitor_user_id: this.input, // 监测人id
           start_time: this.startTime, // 开始时间
           end_time: this.endTime // 结束时间
         })
@@ -235,6 +235,7 @@ export default {
       }
       this.loading = true;
       this.tableData = [];
+      this.page = 1
       this.tableList();
     },
 

+ 5 - 5
minggao/src/page/commandCenter/taskRegulator.vue

@@ -30,10 +30,10 @@
             filterable
             :loading="loading3"
             v-model="input2"
-            @focus="selectList('supervisor')"
+            @focus="selectList('owner')"
             clearable
             @change="searchData"
-            placeholder="请选择任务监督人/实际监督人"
+            placeholder="请选择任务发布人"
             size="mini"
           >
             <el-option
@@ -142,7 +142,7 @@
         </el-table-column>
         <el-table-column
           prop="start_time"
-          label="任务时间"
+          label="任务开始时间"
           width="180"
         ></el-table-column>
         <el-table-column
@@ -555,7 +555,7 @@ export default {
       type_status: [
         {
           name: "未开始",
-          color: "#E6A23C"
+          color: "#409EFF"
         },
         {
           name: "处理中",
@@ -571,7 +571,7 @@ export default {
         },
         {
           name: "逾期完成",
-          color: "#409EFF"
+          color: "#000"
         }
       ],
 

+ 2 - 2
minggao/src/page/forecasting/cbd/Cbd.vue

@@ -903,8 +903,8 @@ export default {
     viewPhotoDialog(id, d_id, name, addr) {
       this.device_id = id;
       this.$router.push({
-        path: `/index/DataPhotos/${id}`,
-        query: { d_id: d_id, name: name, addr: addr },
+        path: `/index/DataPhotos`,
+        query: { id:id,d_id: d_id, name: name, addr: addr },
       });
     },
     //设备控制

+ 6 - 3
minggao/src/page/forecasting/cbd/MessageWarn.vue

@@ -160,7 +160,7 @@
 			</div>
 			<div>
 				<el-button type="primary" @click="submitData()">提交</el-button>
-				<el-button type="info">重置</el-button>
+				<!-- <el-button type="info" @click="chongzhi">重置</el-button> -->
 			</div>
 		</div>
 		<!-- 预览框 -->
@@ -421,7 +421,7 @@ export default {
 			plantObj['pestWarn'] = pestWarn
 
 			let postData = that.qs.stringify({
-				device_id: that.$route.params.id,
+				device_id: that.$route.query.id,
 				conf: JSON.stringify(plantObj)
 			})
 
@@ -457,7 +457,7 @@ export default {
 		warningData() {
 			let that = this
 			let postData = that.qs.stringify({
-				device_id: that.$route.params.id,
+				device_id: that.$route.query.id,
 				conf: ''
 			})
 			that
@@ -503,6 +503,9 @@ export default {
 			//返回上一页
 		goBackPage() {
 			this.$router.go(-1)
+		},
+		chongzhi(){
+
 		}
 	}
 }

+ 21 - 14
minggao/src/page/forecasting/cbd/cbdDataPhotos.vue

@@ -1043,7 +1043,7 @@ export default {
       enlargementImg: true, //图片样式控制
       loading: false, //识别结果加载
       tltName: "", //弹出层标题名
-      id: this.$route.params.id,
+      id: this.$route.query.id,
       //在线状态按钮切换
       equipStatus: "0",
       //设备列表
@@ -1538,7 +1538,7 @@ export default {
         this.delImgFun("");
       }
       if (flag == 6) {
-        this.$router.push(`/index/messageWarn/${this.id}`);
+        this.$router.push(`/index/messageWarn?id=`+this.id);
       }
       if (flag == 7) {
         this.downBtnState = !this.downBtnState;
@@ -1610,7 +1610,9 @@ export default {
         }),
       }).then((res) => {
         if (res.data.message == "") {
-          this.$message.success("指令下发成功!");
+          if (document.getElementsByClassName("el-message").length == 0) {
+            this.$message.success("指令下发成功!");
+          }
         }
       });
     },
@@ -1766,7 +1768,7 @@ export default {
       let postData = that.qs.stringify({
         img_id: this.addFunData.ids,
         ret: "again",
-        device_type: "cbd",
+        // device_type: "cbd",
       });
       console.log(postData);
       console.log(this.addFunData.ids);
@@ -1943,7 +1945,7 @@ export default {
           that
             .$axios({
               method: "post",
-              url: "/api/api_gateway?method=forecast.forecast_system.equip_photo_describe",
+              url: "/api/api_gateway?method=monitor_manage.cbd_manage.cbd_photo_species",
               data: postData,
             })
             .then((res) => {
@@ -1979,7 +1981,7 @@ export default {
     //图片列表数据请求
     imgListData() {
       let that = this;
-      let id = that.$route.params.id;
+      let id = that.$route.query.id;
       console.log("这是结束时间:" + this.queryInfo.end);
       let postData = that.qs.stringify({
         device_id: id,
@@ -1998,6 +2000,11 @@ export default {
           this.disableVal = res.data.data.disable; // 该设备是否有识别功能 0 没有  1有
           if (res.data.data.data.length !== 0 && res.data.data.num !== 0) {
             // 有数据
+            this.$message({
+                showClose: true,
+                message: "数据获取成功",
+                type: "success",
+              });
             var data = res.data.data.data;
             this.totalNum = res.data.data.num;
             var arr = [];
@@ -2120,7 +2127,7 @@ export default {
         that
           .$axios({
             method: "post",
-            url: "/api/api_gateway?method=forecast.forecast_system.equip_photo_describe",
+            url: "/api/api_gateway?method=monitor_manage.cbd_manage.cbd_photo_species",
             data: postData,
           })
           .then((res) => {
@@ -2159,7 +2166,7 @@ export default {
         that
           .$axios({
             method: "post",
-            url: "/api/api_gateway?method=forecast.forecast_system.equip_photo_describe",
+            url: "/api/api_gateway?method=monitor_manage.cbd_manage.cbd_photo_species",
             data: postData,
           })
           .then((res) => {
@@ -2410,7 +2417,7 @@ export default {
       let that = this;
       that.listidentification = "1";
       this.addFunData = data;
-      let id = that.$route.params.id;
+      let id = that.$route.query.id;
       let postData = that.qs.stringify({
         device_id: id,
         // page_number: 8,
@@ -2547,7 +2554,7 @@ export default {
       console.log(time_list);
       console.log(this.imgDataList[0].name);
       let that = this;
-      let id = that.$route.params.id;
+      let id = that.$route.query.id;
       this.$message.success("图片下载中!");
       var idList = JSON.stringify(id_list.length == 0 ? "" : id_list);
       var timeList = JSON.stringify(time_list.length == 0 ? "" : time_list);
@@ -2626,7 +2633,7 @@ export default {
         url: "/api/api_gateway?method=monitor_manage.cbd_manage.cbd_photo_discern",
         data: this.qs.stringify({
           img_id: this.addFunData.ids,
-          cmd: "cbd",
+         ret:"see",
         }),
       }).then((res) => {
         if (res.data.message == "") {
@@ -2714,7 +2721,7 @@ export default {
     // 开启或禁止识别功能
     operationDiscern(ret) {
       var that = this;
-      let id = that.$route.params.id;
+      let id = that.$route.query.id;
       that
         .$axios({
           method: "post",
@@ -2982,7 +2989,7 @@ export default {
     },
     // 树形控件动态获取时间接口测试
     dynamicDataTime(node, resolve) {
-      let id = this.$route.params.id;
+      let id = this.$route.query.id;
       var postData = this.qs.stringify({
         device_id: id,
       });
@@ -3223,7 +3230,7 @@ export default {
 
     // 获取当前设备的设备添加时间动态渲染插件
     deviceAddTime(node, resolve) {
-      var id = this.$route.params.id;
+      var id = this.$route.query.id;
       var postData = this.qs.stringify({
         device_id: id,
         page: 1,

+ 4 - 4
minggao/src/page/forecasting/trap/bait.vue

@@ -31,8 +31,8 @@
             prop="inducer_name"
             label="引诱剂名称"
           ></el-table-column>
-          <el-table-column prop="expire" label="引诱剂有效天数">
-          </el-table-column>
+          <!-- <el-table-column prop="expire" label="引诱剂有效天数">
+          </el-table-column> -->
           <el-table-column prop="messages" label="描述"> </el-table-column>
           <el-table-column label="操作" width="300">
             <template slot-scope="scope">
@@ -76,9 +76,9 @@
           <el-form-item label="诱剂名称" prop="inducer_name">
             <el-input v-model="ruleForm.inducer_name"></el-input>
           </el-form-item>
-          <el-form-item label="有效期天数" prop="expire">
+          <!-- <el-form-item label="有效期天数" prop="expire">
             <el-input v-model="ruleForm.expire"></el-input>
-          </el-form-item>
+          </el-form-item> -->
           <el-form-item label="诱剂描述" prop="messages">
             <el-input type="textarea" v-model="ruleForm.messages"></el-input>
           </el-form-item>

+ 101 - 84
minggao/src/page/forecasting/trap/trap.vue

@@ -123,14 +123,14 @@
               <div class="state">
                 <p
                   :style="{
-                    color: scope.row.trap_status == '1' ? '#30A031 ' : 'red'
+                    color: scope.row.trap_status == '1' ? '#30A031 ' : 'red',
                   }"
                 >
                   ·
                 </p>
                 <p
                   :style="{
-                    color: scope.row.trap_status == '1' ? '#30A031 ' : 'red'
+                    color: scope.row.trap_status == '1' ? '#30A031 ' : 'red',
                   }"
                 >
                   {{ scope.row.trap_status == "1" ? "正常" : "停用" }}
@@ -256,8 +256,11 @@
       </div>
       <span slot="footer" class="dialog-footer">
         <el-button @click="resetForm('ruleForm')" size="mini">取 消</el-button>
-        <el-button type="primary" @click="submitForm('ruleForm')" size="mini"
-        :disabled="releaseTF"
+        <el-button
+          type="primary"
+          @click="submitForm('ruleForm')"
+          size="mini"
+          :disabled="releaseTF"
           >{{ releaseTF ? "发布中..." : "确 定" }}</el-button
         >
       </span>
@@ -295,7 +298,7 @@
         <el-button type="primary" @click="downloadtf = false">确 定</el-button>
       </span> -->
     </el-dialog>
-    <el-dialog title="提示" :visible.sync="deriveVisible" width="30%">
+    <el-dialog title="导出数据" :visible.sync="deriveVisible" width="30%">
       <div class="derivebox">
         <p><span>*</span>文件名称:</p>
         <el-input
@@ -307,7 +310,8 @@
       <span slot="footer" class="dialog-footer">
         <el-button @click="deriveVisible = false" size="mini">取 消</el-button>
         <el-button type="primary" @click="deriveclick" size="mini"
-          >确 定</el-button
+        :disabled="deriveTF"
+          >{{deriveTF?"导出中...":"确 定"}}</el-button
         >
       </span>
     </el-dialog>
@@ -385,7 +389,7 @@ export default {
       inoffvalue: "",
       inoffoptions: [
         { label: "停用", value: "0" },
-        { label: "正常", value: "1" }
+        { label: "正常", value: "1" },
       ],
       versionsvalue: "",
       versionsvalue1: "", //组织id
@@ -397,7 +401,7 @@ export default {
         value: "id",
         children: "childrens",
         multiple: true,
-        checkStrictly: true
+        checkStrictly: true,
       },
       trapvalue: "",
       traponsoptions: [], //监测点
@@ -407,7 +411,7 @@ export default {
         point_id: "", //监测点id
         trap_number: "", //设备id
         org_id: "", //组织id
-        trap_status: "" //状态
+        trap_status: "", //状态
       },
       tableData: [],
       device_id: "",
@@ -422,33 +426,33 @@ export default {
         org_id: "", //     必传(string)               所属海关id
         inducer_id: "", //     必传(string)               诱剂id
         point_id: "", //     必传(string)               所属监测点id
-        trap_status: "" //    必传(string)               设备状态0停用 1正常
+        trap_status: "", //    必传(string)               设备状态0停用 1正常
       },
       rules: {
         trap_number: [
           { required: true, message: "请输入诱捕器编号", trigger: "blur" },
-          { validator: checkname, trigger: "blur" }
+          { validator: checkname, trigger: "blur" },
         ],
         lng: [
-          { required: true, message: "请输入经度", trigger: "blur" }
+          { required: true, message: "请输入经度", trigger: "blur" },
           // { validator: checklnglat, trigger: "blur" },
         ],
         lat: [
-          { required: true, message: "请输入纬度", trigger: "blur" }
+          { required: true, message: "请输入纬度", trigger: "blur" },
           // { validator: checklnglat, trigger: "blur" },
         ],
         org_id: [
-          { required: true, message: "请选择隶属海关", trigger: "change" }
+          { required: true, message: "请选择隶属海关", trigger: "change" },
         ],
         point_id: [
-          { required: true, message: "请选择所在监测点", trigger: "change" }
+          { required: true, message: "请选择所在监测点", trigger: "change" },
         ],
         inducer_id: [
-          { required: true, message: "请选择诱剂名称", trigger: "change" }
+          { required: true, message: "请选择诱剂名称", trigger: "change" },
         ],
         trap_status: [
-          { required: true, message: "请选择设备状态", trigger: "change" }
-        ]
+          { required: true, message: "请选择设备状态", trigger: "change" },
+        ],
       },
       parameter: "",
       addtitle: "新增诱捕器",
@@ -460,20 +464,21 @@ export default {
       addLocationDialogVisible: false,
       locationForm: {
         lng: "",
-        lat: ""
+        lat: "",
       },
       addr: "", //搜索栏地址
       address: "", //地图上标签地址
       center: [114.05, 22.55],
       content: "", //设备列表组织列表
-      releaseTF:false
+      releaseTF: false,
+      deriveTF:false
     };
   },
   //监听属性 类似于data概念
   computed: {},
   //监控data中的数据变化
   watch: {
-    parameter: function(e) {
+    parameter: function (e) {
       // console.log(e);
       if (e == "add") {
         // console.log(this.$data.addtitle)
@@ -481,7 +486,7 @@ export default {
       } else if (e == "modify") {
         this.$data.addtitle = "修改诱捕器";
       }
-    }
+    },
   },
   //方法集合
   methods: {
@@ -497,9 +502,9 @@ export default {
           trap_number: this.queryInfo.trap_number,
           point_id: this.queryInfo.point_id,
           org_id: this.queryInfo.org_id,
-          trap_status: this.queryInfo.trap_status
-        })
-      }).then(res => {
+          trap_status: this.queryInfo.trap_status,
+        }),
+      }).then((res) => {
         this.loading = false;
         console.log(res.data.data);
         this.total = res.data.data.total_item;
@@ -514,9 +519,9 @@ export default {
       this.$axios({
         method: "POST",
         url: "/api/api_gateway?method=sysmenage.usermanager.org_list",
-        data:this.qs.stringify({
+        data: this.qs.stringify({
           page_item: "100000000",
-        })
+        }),
       }).then((res) => {
         console.log(res.data.data);
         this.versionsoptions = res.data.data.page_list; //组织
@@ -528,9 +533,9 @@ export default {
       this.$axios({
         method: "POST",
         url: "/api/api_gateway?method=monitor_manage.trap_manage.trap_org",
-        data:this.qs.stringify({
-          page_item:"10000000"
-        })
+        data: this.qs.stringify({
+          page_item: "10000000",
+        }),
       }).then((res) => {
         console.log(res.data.data);
         this.versionsoptions2 = res.data.data.org_data; //组织
@@ -571,7 +576,7 @@ export default {
         org_id = org_id.join("/");
       }
       console.log(org_id);
-      this.releaseTF = true
+      this.releaseTF = true;
       this.$refs[formName].validate((valid) => {
         if (valid) {
           this.$axios({
@@ -586,9 +591,9 @@ export default {
               inducer_id: this.ruleForm.inducer_id, //                必传(string)               诱剂id
               point_id: this.ruleForm.point_id, //                  必传(string)               所属监测点id
               trap_status: this.ruleForm.trap_status, //               必传(string)               设备状态0停用 1正常
-              parameter: this.parameter
-            })
-          }).then(res => {
+              parameter: this.parameter,
+            }),
+          }).then((res) => {
             console.log(res);
             if (res.data.data) {
               var message = "";
@@ -601,7 +606,7 @@ export default {
               this.$message({
                 showClose: true,
                 message: message,
-                type: "success"
+                type: "success",
               });
               this.addtraptf = false;
               this.getcbdlist();
@@ -609,16 +614,16 @@ export default {
               this.$message({
                 showClose: true,
                 message: "添加失败" + res.data.message,
-                type: "warning"
+                type: "warning",
               });
             }
-            this.releaseTF = false
+            this.releaseTF = false;
           });
         } else {
           if (document.getElementsByClassName("el-message").length == 0) {
             this.$message({
               message: "请将信息填写完全",
-              type: "warning"
+              type: "warning",
             });
           }
           return false;
@@ -652,12 +657,11 @@ export default {
     getmon3(trap_id) {
       this.$axios({
         method: "POST",
-        url:
-          "/api/api_gateway?method=sysmenage.usermanager.get_parent_org_list;",
+        url: "/api/api_gateway?method=sysmenage.usermanager.get_parent_org_list;",
         data: this.qs.stringify({
-          device_id: trap_id
-        })
-      }).then(res => {
+          device_id: trap_id,
+        }),
+      }).then((res) => {
         // console.log(res.data.data);
         var orgdatas = res.data.data;
         if (orgdatas.length != 0) {
@@ -679,7 +683,7 @@ export default {
       var str = "您确定删除编号为<" + events.trap_number + ">的诱捕器吗?";
       this.$confirm(str, "删除诱捕器", {
         confirmButtonText: "确定",
-        cancelButtonText: "取消"
+        cancelButtonText: "取消",
       })
         .then(() => {
           this.$axios({
@@ -687,22 +691,22 @@ export default {
             url: "/api/api_gateway?method=monitor_manage.trap_manage.add_trap",
             data: this.qs.stringify({
               trap_id: events.trap_id,
-              parameter: "del"
-            })
-          }).then(res => {
+              parameter: "del",
+            }),
+          }).then((res) => {
             console.log(res);
             if (res.data.data) {
               this.$message({
                 showClose: true,
                 message: "删除成功!",
-                type: "success"
+                type: "success",
               });
               this.getcbdlist();
             } else {
               this.$message({
                 showClose: true,
                 message: "删除失败," + res.data.message,
-                type: "warning"
+                type: "warning",
               });
             }
           });
@@ -710,7 +714,7 @@ export default {
         .catch(() => {
           this.$message({
             type: "info",
-            message: "已取消删除"
+            message: "已取消删除",
           });
         });
     },
@@ -723,15 +727,15 @@ export default {
         method: "POST",
         url: "/api/trap_export",
         data: datas,
-        responseType: "blob"
-      }).then(res => {
+        responseType: "blob",
+      }).then((res) => {
         console.log(res);
         this.downloadFile(res, "allot_result.xls");
       });
     },
     download() {
       //下载模板
-      console.log(22222)
+      console.log(22222);
       window.location.href =
         // this.$deriveData +
         // "http://192.168.1.77:12345/api/trap_export";1
@@ -746,28 +750,41 @@ export default {
       document.body.appendChild(link);
       link.click();
       document.body.removeChild(link);
+       this.deriveTF = false
     },
     deriveclick() {
       // this.deriveVisible = false;
-      this.$axios({
-        method: "POST",
-        url: "api/trap_list_export",
-        data: this.qs.stringify({
-          trap_number: this.ruleForm.trap_number,
-          point_id: this.ruleForm.point_id,
-          org_id: this.ruleForm.org_id,
-          trap_status: this.ruleForm.trap_status,
-          file_name: this.derivefilename,
-          user: localStorage.getItem("usernme")
-        }),
-        responseType: "blob"
-      }).then(res => {
-        console.log(res);
-        this.downloadFile(res, this.derivefilename + ".xls");
-      });
+      if (this.derivefilename == "") {
+        this.$message({
+                showClose: true,
+                message: "请输入文件名称",
+                type: "warning",
+              });
+      } else {
+        this.deriveTF = true
+        this.$axios({
+          method: "POST",
+          url: "api/trap_list_export",
+          data: this.qs.stringify({
+            trap_number: this.ruleForm.trap_number,
+            point_id: this.ruleForm.point_id,
+            org_id: this.ruleForm.org_id,
+            trap_status: this.ruleForm.trap_status,
+            file_name: this.derivefilename,
+            user: localStorage.getItem("usernme"),
+          }),
+          responseType: "blob",
+        }).then((res) => {
+          console.log(res);
+          this.downloadFile(res, this.derivefilename + ".xls");
+        });
+      }
     },
     reset() {
       //重置
+      this.idinput = "";
+      this.trapvalue = "";
+      this.inoffvalue = "";
       this.queryInfo.trap_number = "";
       this.queryInfo.point_id = "";
       this.queryInfo.org_id = "";
@@ -782,18 +799,18 @@ export default {
         center: this.center,
         resizeEnable: true,
         zoom: 10,
-        lang: "en"
+        lang: "en",
       });
       AMap.plugin(["AMap.ToolBar", "AMap.Geocoder"], () => {
         map.addControl(new AMap.ToolBar());
         this.geocoder = new AMap.Geocoder({
           city: "全国",
-          radius: 1000
+          radius: 1000,
         });
       });
       setTimeout(() => {
         var marker = new AMap.Marker({
-          position: this.center
+          position: this.center,
         });
         console.log(this.center);
         marker.setMap(map);
@@ -812,7 +829,7 @@ export default {
           this.map.setFitView(marker);
           this.locationForm = {
             lat: lnglat.lat,
-            lng: lnglat.lng
+            lng: lnglat.lng,
           };
         } else {
           this.$message.error("根据地址查询位置失败");
@@ -821,19 +838,19 @@ export default {
     },
     // 地图点击事件
     testevent() {
-      this.map.on("click", ev => {
+      this.map.on("click", (ev) => {
         var lnglat = [ev.lnglat.lng, ev.lnglat.lat];
         this.locationForm = { lng: lnglat[0], lat: lnglat[1] };
         this.map.clearMap();
         var marker = new AMap.Marker({
-          position: lnglat
+          position: lnglat,
         });
         marker.setMap(this.map);
         this.getAddress(lnglat);
         setTimeout(() => {
           new AMap.InfoWindow({
             content: "<h5>" + "当前选中地址" + "</h5>" + this.address,
-            offset: new AMap.Pixel(0, -32)
+            offset: new AMap.Pixel(0, -32),
           }).open(this.map, lnglat);
         }, 100);
       });
@@ -863,7 +880,7 @@ export default {
       if (this.locationForm.lat && this.locationForm.lng) {
         let lnglat = [this.locationForm.lng, this.locationForm.lat];
         var marker = new AMap.Marker({
-          position: lnglat
+          position: lnglat,
         });
         marker.setMap(this.map);
       } else {
@@ -872,16 +889,16 @@ export default {
       }
     },
     dingwei() {
-      console.log(this.ruleForm)
+      console.log(this.ruleForm);
       if (this.ruleForm.lng != "" && this.ruleForm.lng != 0) {
         this.center[0] = this.ruleForm.lng;
-      }else{
-        this.center = [114.05, 22.55]
+      } else {
+        this.center = [114.05, 22.55];
       }
       if (this.ruleForm.lat != "" && this.ruleForm.lat != 0) {
         this.center[1] = this.ruleForm.lat;
-      }else{
-        this.center = [114.05, 22.55]
+      } else {
+        this.center = [114.05, 22.55];
       }
       this.addLocationDialogVisible = true;
       setTimeout(() => {
@@ -959,7 +976,7 @@ export default {
         str += `<p>` + e.org_list[i].org_name + `</p>`;
       }
       this.content = str;
-    }
+    },
   },
   beforeCreate() {}, //生命周期 - 创建之前
   //生命周期 - 创建完成(可以访问当前this实例)
@@ -975,7 +992,7 @@ export default {
   updated() {}, //生命周期 - 更新之后
   beforeDestroy() {}, //生命周期 - 销毁之前
   destroyed() {}, //生命周期 - 销毁完成
-  activated() {} //如果页面有keep-alive缓存功能,这个函数会触发
+  activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
 };
 </script>
 <style scoped lang="less">

+ 1 - 1
minggao/src/page/home/index.vue

@@ -93,7 +93,7 @@
               v-for="(item, index) in routerinfo"
               :key="item.pur_id"
               ><a
-                v-if="index == routerinfo.length - 2 && item.menu != ''"
+                v-if="index == routerinfo.length - 2 && item.menu != ''&&item.purview_name!='查看图片'"
                 :href="'/#/index/' + item.menu"
                 style="cursor: pointer"
                 >{{ item.purview_name }}</a

+ 1 - 1
minggao/src/page/homepage/facilitydistribute.vue

@@ -131,7 +131,7 @@
               <span>{{ item.pest_name }}</span
               ><span>{{ item.sum }}</span>
             </p>
-            <p style="color: #fff; width: 100%; text-align: center">暂无数据</p>
+            <p style="color: #fff; width: 100%; text-align: center" v-if="baseinfo[0].pest_list.length==0">暂无数据</p>
           </div>
         </div>
         <div class="cbdinfobox" v-if="device_type_id == 3">

+ 4 - 2
minggao/src/page/homepage/pestdistribute.vue

@@ -574,7 +574,7 @@ export default {
         } else {
           this.ruleForm.threshold = res.data.data.threshold;
         }
-        this.init(trap_data_arr);
+        
         var pest_count = res.data.data.pest_count;
         var arr = [];
         for (var i = 0; i < pest_count.length; i++) {
@@ -584,7 +584,9 @@ export default {
           };
           arr.push(obj);
         }
-        
+        this.$nextTick(()=>{
+          this.init(trap_data_arr);
+        })
         this.initpie(arr);
       });
     },

+ 2 - 2
minggao/src/router/index.js

@@ -228,7 +228,7 @@ export default new Router({
           component: DataDetails
         },
         {
-          path: 'DataPhotos/:id',
+          path: 'DataPhotos',
           component: DataPhotos
         },
         {
@@ -244,7 +244,7 @@ export default new Router({
           component: deviceTongji
         },
         {
-          path: 'MessageWarn/:id',
+          path: 'MessageWarn',
           component: MessageWarn
         },
         {