1
0

2 Commits 5414116f2b ... 9aa724157b

Autor SHA1 Mensagem Data
  yf_wsy 9aa724157b 合并提交 3 years atrás
  yf_wsy 9f49d5a0d0 病害折线图分割 3 years atrás

+ 3 - 4
pages.json

@@ -485,7 +485,7 @@
 		}, {
 		}, {
 			"path": "pages/disease/cmb",
 			"path": "pages/disease/cmb",
 			"style": {
 			"style": {
-				"navigationBarTitleText": "小麦赤霉病设备详情页",
+				"navigationBarTitleText": "病设备详情页",
 				"enablePullDownRefresh": false,
 				"enablePullDownRefresh": false,
 				"navigationStyle": "custom"
 				"navigationStyle": "custom"
 			}
 			}
@@ -493,9 +493,8 @@
 		},{
 		},{
 			"path": "pages/disease/forecastResult",
 			"path": "pages/disease/forecastResult",
 			"style": {
 			"style": {
-				"navigationBarTitleText": "病害设备详情页",
-				"enablePullDownRefresh": false,
-				"navigationStyle": "custom"
+				"navigationBarTitleText": "预测结果",
+				"enablePullDownRefresh": false
 			}
 			}
 
 
 		},{
 		},{

+ 1 - 1
pages/cb/index/index.vue

@@ -138,7 +138,7 @@
 								this.equipArr[1].tf = true//"孢子仪"
 								this.equipArr[1].tf = true//"孢子仪"
 								this.getEquipList(1)
 								this.getEquipList(1)
 								break
 								break
-							case 159:
+							case 161:
 								this.equipArr[3].tf = true//"性诱2.0"
 								this.equipArr[3].tf = true//"性诱2.0"
 								this.getxyEquipList(3)
 								this.getxyEquipList(3)
 								break
 								break

+ 122 - 36
pages/disease/cmb.vue

@@ -93,6 +93,23 @@
               'margin-top': (-cHeight * (pixelRatio - 1)) / 2 + 'px',
               'margin-top': (-cHeight * (pixelRatio - 1)) / 2 + 'px',
             }"
             }"
           ></canvas>
           ></canvas>
+          <canvas
+            v-show="!tiemshow"
+            canvas-id="canvasColumnB"
+            id="canvasColumnB"
+            class="charts"
+            @touchstart="touchLineB($event)"
+            @touchmove="moveLineB($event)"
+            @touchend="touchEndLineB($event)"
+            disable-scroll="true"
+            :style="{
+              width: cWidth * pixelRatio + 'px',
+              height: cHeight * pixelRatio + 'px',
+              transform: 'scale(' + 1 / pixelRatio + ')',
+              'margin-left': (-cWidth * (pixelRatio - 1)) / 2 + 'px',
+              'margin-top': (-cHeight * (pixelRatio - 1)) / 2 + 'px',
+            }"
+          ></canvas>
         </view>
         </view>
         <view class="condition">
         <view class="condition">
           <scroll-view scroll-top="0" scroll-x="true" class="scroll-X">
           <scroll-view scroll-top="0" scroll-x="true" class="scroll-X">
@@ -153,6 +170,7 @@
 <script>
 <script>
 import uCharts from "../../components/js_sdk/u-charts/u-charts/u-charts.js";
 import uCharts from "../../components/js_sdk/u-charts/u-charts/u-charts.js";
 var canvaColumnA = null;
 var canvaColumnA = null;
+var canvaColumnB = null;
 export default {
 export default {
   data() {
   data() {
     return {
     return {
@@ -266,9 +284,11 @@ export default {
       });
       });
     },
     },
     tiemchange(e) {
     tiemchange(e) {
+      console.log(e);
       //切换时间
       //切换时间
-      this.begintime = parseInt(+new Date(e.startDate) / 1000);
-      this.end = parseInt(+new Date(e.endDate) / 1000);
+      // this.begintime = parseInt(+new Date(e.startDate) / 1000);
+      this.begintime = parseInt(+new Date(`${e.startDate} 00:00:00`) / 1000);
+      this.end = parseInt(+new Date(`${e.endDate} 00:00:00`) / 1000);
       this.histprydatas();
       this.histprydatas();
       this.getChartLine();
       this.getChartLine();
     },
     },
@@ -370,11 +390,23 @@ export default {
           }
           }
         }
         }
         console.log(regroupData);
         console.log(regroupData);
-        this.showColumn("canvasColumnA", xtitle, regroupData);
+        // 分割折线图
+        const regroupDataNum = Math.ceil(regroupData.length / 2);
+        const options1 = regroupData.filter((v, i) => {
+          return i < regroupDataNum;
+        });
+        const options2 = regroupData.filter((v, i) => {
+          return i >= regroupDataNum;
+        });
+        console.log(options1, options1);
+
+        this.showColumn("canvasColumnA", xtitle, options1);
+        this.showColumn("canvasColumnB", xtitle, options2);
         this.canvastishiTF = true;
         this.canvastishiTF = true;
       } else {
       } else {
         this.canvastishiTF = false;
         this.canvastishiTF = false;
         this.showColumn("canvasColumnA", xtitle, []);
         this.showColumn("canvasColumnA", xtitle, []);
+        this.showColumn("canvasColumnB", xtitle, []);
       }
       }
     },
     },
     prev() {
     prev() {
@@ -397,41 +429,79 @@ export default {
       });
       });
     },
     },
     showColumn(id, xtitle, xinfo) {
     showColumn(id, xtitle, xinfo) {
+      console.log(id);
       var _self = this;
       var _self = this;
-      canvaColumnA = new uCharts({
-        canvasId: id,
-        type: "line",
-        legend: {
-          position: "top",
-        },
-        fontSize: 11,
-        background: "#FFFFFF",
-        pixelRatio: 1,
-        animation: true,
-        dataLabel: false,
-        categories: xtitle,
-        series: xinfo,
-        enableScroll: true, //开启图表拖拽功能
-        xAxis: {
-          disableGrid: true,
-          type: "grid",
-          gridType: "dash",
-          itemCount: 4, //x轴单屏显示数据的数量,默认为5个
-          scrollShow: true, //新增是否显示滚动条,默认false
-          // scrollAlign: 'left', //滚动条初始位置
-          scrollBackgroundColor: "#F7F7FF", //默认为 #EFEBEF
-          scrollColor: "#DEE7F7", //默认为 #A6A6A6
-        },
-        yAxis: {},
-        width: _self.cWidth * 1,
-        height: _self.cHeight * 1,
-        extra: {
-          line: {
-            type: "curve",
+      if (id === "canvasColumnA") {
+        canvaColumnA = new uCharts({
+          canvasId: id,
+          type: "line",
+          legend: {
+            position: "top",
           },
           },
-        },
-      });
+          fontSize: 11,
+          background: "#FFFFFF",
+          pixelRatio: 1,
+          animation: true,
+          dataLabel: false,
+          categories: xtitle,
+          series: xinfo,
+          enableScroll: true, //开启图表拖拽功能
+          xAxis: {
+            disableGrid: true,
+            type: "grid",
+            gridType: "dash",
+            itemCount: 4, //x轴单屏显示数据的数量,默认为5个
+            scrollShow: true, //新增是否显示滚动条,默认false
+            // scrollAlign: 'left', //滚动条初始位置
+            scrollBackgroundColor: "#F7F7FF", //默认为 #EFEBEF
+            scrollColor: "#DEE7F7", //默认为 #A6A6A6
+          },
+          yAxis: {},
+          width: _self.cWidth * 1,
+          height: _self.cHeight * 1,
+          extra: {
+            line: {
+              type: "curve",
+            },
+          },
+        });
+      } else if (id === "canvasColumnB") {
+        canvaColumnB = new uCharts({
+          canvasId: id,
+          type: "line",
+          legend: {
+            position: "top",
+          },
+          fontSize: 11,
+          background: "#FFFFFF",
+          pixelRatio: 1,
+          animation: true,
+          dataLabel: false,
+          categories: xtitle,
+          series: xinfo,
+          enableScroll: true, //开启图表拖拽功能
+          xAxis: {
+            disableGrid: true,
+            type: "grid",
+            gridType: "dash",
+            itemCount: 4, //x轴单屏显示数据的数量,默认为5个
+            scrollShow: true, //新增是否显示滚动条,默认false
+            // scrollAlign: 'left', //滚动条初始位置
+            scrollBackgroundColor: "#F7F7FF", //默认为 #EFEBEF
+            scrollColor: "#DEE7F7", //默认为 #A6A6A6
+          },
+          yAxis: {},
+          width: _self.cWidth * 1,
+          height: _self.cHeight * 1,
+          extra: {
+            line: {
+              type: "curve",
+            },
+          },
+        });
+      }
     },
     },
+
     touchLineA(e) {
     touchLineA(e) {
       console.log(e);
       console.log(e);
       canvaColumnA.scrollStart(e);
       canvaColumnA.scrollStart(e);
@@ -448,6 +518,22 @@ export default {
         },
         },
       });
       });
     },
     },
+    touchLineB(e) {
+      console.log(e);
+      canvaColumnB.scrollStart(e);
+    },
+    moveLineB(e) {
+      canvaColumnB.scroll(e);
+    },
+    touchEndLineB(e) {
+      canvaColumnB.scrollEnd(e);
+      //下面是toolTip事件,如果滚动后不需要显示,可不填写
+      canvaColumnB.showToolTip(e, {
+        format: function (item, category) {
+          return category + " " + item.name + ":" + item.data;
+        },
+      });
+    },
   },
   },
   onLoad(option) {
   onLoad(option) {
     this.eqinfo = JSON.parse(option.shebei);
     this.eqinfo = JSON.parse(option.shebei);
@@ -593,7 +679,7 @@ export default {
   margin: 20px auto;
   margin: 20px auto;
   box-shadow: 0 0 10rpx #bcb9ca;
   box-shadow: 0 0 10rpx #bcb9ca;
   padding-top: 20rpx;
   padding-top: 20rpx;
-  height: 550rpx;
+  height: 1000rpx;
 
 
   .canvastishi {
   .canvastishi {
     font-size: 32rpx;
     font-size: 32rpx;

+ 6 - 64
pages/disease/forecastResult.vue

@@ -1,15 +1,15 @@
 <template>
 <template>
   <view>
   <view>
-    <view class="status_bar"></view>
-    <view class="" style="position: relative; top: 44px">
-      <view style="position: fixed; z-index: 100; width: 100%">
+    <!-- <view class="status_bar"></view> -->
+    <view class="">
+      <!-- <view style="position: fixed; z-index: 100; width: 100%">
         <uni-nav-bar
         <uni-nav-bar
           @clickLeft="clickLeft"
           @clickLeft="clickLeft"
           left-icon="back"
           left-icon="back"
           left-text="返回"
           left-text="返回"
           title="设备详情"
           title="设备详情"
         ></uni-nav-bar>
         ></uni-nav-bar>
-      </view>
+      </view> -->
       <view class="info">
       <view class="info">
         <view class="info_item">
         <view class="info_item">
           <image
           <image
@@ -28,7 +28,7 @@
           <p>预测位置:{{ this.address || "无" }}</p>
           <p>预测位置:{{ this.address || "无" }}</p>
           <p>
           <p>
             最近预测时间:<span v-if="this.latest_uptime != ''">{{
             最近预测时间:<span v-if="this.latest_uptime != ''">{{
-              this.latest_uptime | timeFormat()
+               formetDate(this.latest_uptime)
             }}</span>
             }}</span>
             <span v-else>暂无数据</span>
             <span v-else>暂无数据</span>
           </p>
           </p>
@@ -196,23 +196,6 @@ export default {
         return "大发生";
         return "大发生";
       }
       }
     },
     },
-    // tiemchange(e) {
-    //   //切换时间
-    //   this.begintime = parseInt(+new Date(e.startDate) / 1000);
-    //   this.end = parseInt(+new Date(e.endDate) / 1000);
-    //   this.histprydatas();
-    //   this.getChartLine();
-    // },
-    // timetab(e) {
-    //   //时间转换
-    //   e = new Date(e * 1000);
-    //   var year = e.getFullYear();
-    //   var month =
-    //     e.getMonth() + 1 < 10 ? "0" + (e.getMonth() + 1) : e.getMonth() + 1;
-    //   var day = e.getDate() < 10 ? "0" + e.getDate() : e.getDate();
-    //   var time = year + "/" + month + "/" + day;
-    //   return time;
-    // },
     // 表格数据
     // 表格数据
     async histprydatas() {
     async histprydatas() {
       //表格历史数据
       //表格历史数据
@@ -275,42 +258,7 @@ export default {
         delta: 1,
         delta: 1,
       });
       });
     },
     },
-    // showColumn(id, xtitle, xinfo) {
-    //   var _self = this;
-    //   canvaColumnA = new uCharts({
-    //     canvasId: id,
-    //     type: "line",
-    //     legend: {
-    //       position: "top",
-    //     },
-    //     fontSize: 11,
-    //     background: "#FFFFFF",
-    //     pixelRatio: 1,
-    //     animation: true,
-    //     dataLabel: false,
-    //     categories: xtitle,
-    //     series: xinfo,
-    //     enableScroll: true, //开启图表拖拽功能
-    //     xAxis: {
-    //       disableGrid: true,
-    //       type: "grid",
-    //       gridType: "dash",
-    //       itemCount: 4, //x轴单屏显示数据的数量,默认为5个
-    //       scrollShow: true, //新增是否显示滚动条,默认false
-    //       // scrollAlign: 'left', //滚动条初始位置
-    //       scrollBackgroundColor: "#F7F7FF", //默认为 #EFEBEF
-    //       scrollColor: "#DEE7F7", //默认为 #A6A6A6
-    //     },
-    //     yAxis: {},
-    //     width: _self.cWidth * 1,
-    //     height: _self.cHeight * 1,
-    //     extra: {
-    //       line: {
-    //         type: "curve",
-    //       },
-    //     },
-    //   });
-    // },
+
     touchLineA(e) {
     touchLineA(e) {
       console.log(e);
       console.log(e);
       canvaColumnA.scrollStart(e);
       canvaColumnA.scrollStart(e);
@@ -334,8 +282,6 @@ export default {
     this.cWidth = uni.upx2px(650);
     this.cWidth = uni.upx2px(650);
     this.cHeight = uni.upx2px(500);
     this.cHeight = uni.upx2px(500);
     this.device_id = option.id;
     this.device_id = option.id;
-    // this.end = parseInt(+new Date() / 1000);
-    // this.begintime = parseInt(this.end - 24 * 60 * 60);
     this.histprydatas();
     this.histprydatas();
   },
   },
 };
 };
@@ -344,9 +290,6 @@ export default {
 <style lang="scss">
 <style lang="scss">
 .info {
 .info {
   width: 100%;
   width: 100%;
-  position: absolute;
-  top: 44px;
-
   .info_item {
   .info_item {
     width: 90%;
     width: 90%;
     margin: 0 auto;
     margin: 0 auto;
@@ -378,7 +321,6 @@ export default {
 }
 }
 .his_box {
 .his_box {
   width: 100%;
   width: 100%;
-  top: 340rpx;
   position: relative;
   position: relative;
   .title {
   .title {
     padding: 20rpx 50rpx;
     padding: 20rpx 50rpx;

+ 27 - 3
pages/environment/index.vue

@@ -247,6 +247,7 @@ export default {
   },
   },
   methods: {
   methods: {
     async eqlist() {
     async eqlist() {
+      console.log("搜素字段s", this.imports);
       //设备列表 环境监测
       //设备列表 环境监测
       this.loadingtf = true;
       this.loadingtf = true;
       const res = await this.$myRequest({
       const res = await this.$myRequest({
@@ -294,7 +295,7 @@ export default {
         method: "POST",
         method: "POST",
         url: "/api/api_gateway?method=wheat.wheat.wheat_list",
         url: "/api/api_gateway?method=wheat.wheat.wheat_list",
         data: {
         data: {
-          device_id: "",
+          device_id: this.imports,
           device_name: "",
           device_name: "",
           page: this.page,
           page: this.page,
           device_type: this.diseaseId,
           device_type: this.diseaseId,
@@ -379,6 +380,13 @@ export default {
         } else if (this.side_type == 15) {
         } else if (this.side_type == 15) {
           this.eqlistdata = [];
           this.eqlistdata = [];
           this.tubulareqlist();
           this.tubulareqlist();
+        } else if (
+          this.side_type == 11 ||
+          this.side_type == 19 ||
+          this.side_type == 20
+        ) {
+          this.eqlistdata = [];
+          this.getEquipList();
         }
         }
       }, 1000)();
       }, 1000)();
     },
     },
@@ -482,6 +490,7 @@ export default {
 page {
 page {
   background: $uni-bg-color-grey;
   background: $uni-bg-color-grey;
 }
 }
+
 .inputs {
 .inputs {
   height: 54rpx;
   height: 54rpx;
   background-color: #e4e4e4;
   background-color: #e4e4e4;
@@ -526,25 +535,37 @@ page {
   left: 2.5%;
   left: 2.5%;
   text-align: center;
   text-align: center;
   z-index: 9;
   z-index: 9;
+
   .img {
   .img {
     width: 300rpx;
     width: 300rpx;
     height: 40rpx;
     height: 40rpx;
   }
   }
 }
 }
+.tab-box::-webkit-scrollbar {
+  display: none;
+}
 .tab-box {
 .tab-box {
   position: fixed;
   position: fixed;
   top: 170px;
   top: 170px;
-  display: flex;
-  justify-content: space-around;
+  // display: flex;
+  // justify-content: space-around;
   font-size: 30rpx;
   font-size: 30rpx;
   line-height: 80rpx;
   line-height: 80rpx;
   background-color: #ffffff;
   background-color: #ffffff;
   width: 100%;
   width: 100%;
   z-index: 2;
   z-index: 2;
+  overflow: hidden;
+  overflow-x: scroll;
+  white-space: nowrap;
+
   .tab-item {
   .tab-item {
     cursor: pointer;
     cursor: pointer;
     position: relative;
     position: relative;
+    width: 25%;
+    text-align: center;
+    display: inline-block;
   }
   }
+
   .tab-item.active {
   .tab-item.active {
     .bottom-line {
     .bottom-line {
       bottom: 0;
       bottom: 0;
@@ -559,6 +580,7 @@ page {
     }
     }
   }
   }
 }
 }
+
 .prevents {
 .prevents {
   width: 100%;
   width: 100%;
   position: absolute;
   position: absolute;
@@ -573,6 +595,7 @@ page {
     box-sizing: border-box;
     box-sizing: border-box;
     position: relative;
     position: relative;
     background-color: #fff;
     background-color: #fff;
+
     .prevents_item_img {
     .prevents_item_img {
       width: 30rpx;
       width: 30rpx;
       height: 50rpx;
       height: 50rpx;
@@ -602,6 +625,7 @@ page {
       margin-top: 20rpx;
       margin-top: 20rpx;
       font-size: 26rpx;
       font-size: 26rpx;
       color: #bdbdbd;
       color: #bdbdbd;
+
       .prevents_item_bot_sapn0 {
       .prevents_item_bot_sapn0 {
         color: #00b075;
         color: #00b075;
       }
       }

+ 3 - 1
pages/equipList/index.vue

@@ -14,6 +14,7 @@
           placeholder-color="#909696"
           placeholder-color="#909696"
           :show-action="false"
           :show-action="false"
           search-icon-color="#909696"
           search-icon-color="#909696"
+          @input="searchinput"
         >
         >
         </u-search>
         </u-search>
         <!-- <input type="text" value="" placeholder="请输入设备ID或设备名称" v-model="imports" @input="searchinput"
         <!-- <input type="text" value="" placeholder="请输入设备ID或设备名称" v-model="imports" @input="searchinput"
@@ -81,7 +82,7 @@
             </view>
             </view>
             <view
             <view
               class="list_item_btn"
               class="list_item_btn"
-              v-if="infoalter && ![11, 19, 20].includes(type_id)"
+              v-if="infoalter && ![13, 17, 18, 11, 19, 20].includes(type_id)"
               @click.stop="modification(item)"
               @click.stop="modification(item)"
             >
             >
               信息修改
               信息修改
@@ -227,6 +228,7 @@ export default {
         };
         };
         this.list.push(obj);
         this.list.push(obj);
       }
       }
+      console.log("设备列表11111111111111", this.list);
       if (res.length) {
       if (res.length) {
         this.type_id = this.list[0].id;
         this.type_id = this.list[0].id;
         if (this.list[0].id == 10) {
         if (this.list[0].id == 10) {

BIN
unpackage/cache/apk/__UNI__DBA6730_cm.apk


+ 5 - 1
unpackage/cache/apk/apkurl

@@ -1 +1,5 @@
-https://ide.dcloud.net.cn/build/download/e6f40ec0-d04c-11ec-8e8d-d9b3e424cb29
+<<<<<<< HEAD
+https://ide.dcloud.net.cn/build/download/f4fea6b0-d102-11ec-9936-a9114ee0f763
+=======
+https://ide.dcloud.net.cn/build/download/e6f40ec0-d04c-11ec-8e8d-d9b3e424cb29
+>>>>>>> 5414116f2bdb506d174436e6db8052c03bb30109

File diff suppressed because it is too large
+ 5 - 1
unpackage/cache/apk/cmManifestCache.json


+ 4 - 0
unpackage/cache/certdata

@@ -1,3 +1,7 @@
+<<<<<<< HEAD
+andrCertfile=E:/HBuilderX/HBuilderX/plugins/app-safe-pack/Test.keystore
+=======
 andrCertfile=D:/HBuilderX/HBuilderX/plugins/app-safe-pack/Test.keystore
 andrCertfile=D:/HBuilderX/HBuilderX/plugins/app-safe-pack/Test.keystore
+>>>>>>> 5414116f2bdb506d174436e6db8052c03bb30109
 andrCertAlias=android
 andrCertAlias=android
 andrCertPass=ep/Tdjka4Y7WYqDB6/S7dw==
 andrCertPass=ep/Tdjka4Y7WYqDB6/S7dw==

File diff suppressed because it is too large
+ 4 - 0
unpackage/cache/wgt/__UNI__DBA6730/app-config-service.js


File diff suppressed because it is too large
+ 5 - 1
unpackage/cache/wgt/__UNI__DBA6730/app-service.js


File diff suppressed because it is too large
+ 5 - 1
unpackage/cache/wgt/__UNI__DBA6730/app-view.js


File diff suppressed because it is too large
+ 4 - 0
unpackage/dist/build/app-plus/app-config-service.js


File diff suppressed because it is too large
+ 5 - 1
unpackage/dist/build/app-plus/app-service.js


File diff suppressed because it is too large
+ 5 - 1
unpackage/dist/build/app-plus/app-view.js


BIN
unpackage/release/apk/__UNI__DBA6730__20220510183525.apk


+ 1 - 1
util/neutral.js

@@ -1,4 +1,4 @@
 export default{
 export default{
 	// isneutral:true//云飞智控
 	// isneutral:true//云飞智控
-	isneutral:false//
+	isneutral:false//
 }
 }