Przeglądaj źródła

release: bump version to 1.15.18 and update feature details

1. update app version from 1.15.17 to 1.15.18
2. fix equipment list page jump path
3. add unit for photo upload frequency display
4. add cmd parameter passing for device detail page
5. adjust image scaling ratio in photo page
6. add admin tab display logic based on user type
7. update api base url configuration
allen 5 dni temu
rodzic
commit
25ac76a2cb

+ 2 - 2
manifest.json

@@ -2,8 +2,8 @@
     "name" : "智控",
     "name" : "智控",
     "appid" : "__UNI__DBA6730",
     "appid" : "__UNI__DBA6730",
     "description" : "",
     "description" : "",
-    "versionName" : "1.15.17",
-    "versionCode" : 11517,
+    "versionName" : "1.15.18",
+    "versionCode" : 11518,
     "transformPx" : false,
     "transformPx" : false,
     "sassImplementationName" : "node-sass",
     "sassImplementationName" : "node-sass",
     /* 5+App特有相关 */
     /* 5+App特有相关 */

+ 1 - 1
pages/bzy/detail.vue

@@ -201,7 +201,7 @@ export default {
 		modification() {
 		modification() {
       uni.navigateTo({
       uni.navigateTo({
         url:
         url:
-          '/pages/equipList/seabox/modification?data=' +
+          '/pages/equipList2/seabox/modification?data=' +
           JSON.stringify(this.deviceInfo) +
           JSON.stringify(this.deviceInfo) +
           '&id=' +
           '&id=' +
           this.deviceInfo.type,
           this.deviceInfo.type,

+ 9 - 1
pages/equipList2/index.vue

@@ -437,9 +437,17 @@
 						// 	url: '../cb/equip-detail/equip-detail-new?info=' +
 						// 	url: '../cb/equip-detail/equip-detail-new?info=' +
 						// 		JSON.stringify(item),
 						// 		JSON.stringify(item),
 						// });
 						// });
+						let cmd = ''
+						if(type_id == 34){
+							cmd = 'sy1'
+						}else if(type_id == 33){
+							cmd = 'sy2'
+						}
 						uni.navigateTo({
 						uni.navigateTo({
 							url: '../sy/detail?info=' +
 							url: '../sy/detail?info=' +
-								JSON.stringify(item),
+								JSON.stringify(item) +
+								'&cmd=' +
+								cmd,
 						});
 						});
 						break;
 						break;
 					case 7:
 					case 7:

+ 1 - 1
pages/scd/detail.vue

@@ -210,7 +210,7 @@ export default {
 		modification() {
 		modification() {
       uni.navigateTo({
       uni.navigateTo({
         url:
         url:
-          '/pages/equipList/seabox/modification?data=' +
+          '/pages/equipList2/seabox/modification?data=' +
           JSON.stringify(this.deviceInfo) +
           JSON.stringify(this.deviceInfo) +
           '&id=' +
           '&id=' +
           this.deviceInfo.type,
           this.deviceInfo.type,

+ 1 - 1
pages/sy/components/deviceData.vue

@@ -85,7 +85,7 @@
             <text class="data-label">控制模式</text>
             <text class="data-label">控制模式</text>
           </view>
           </view>
           <view class="data-item">
           <view class="data-item">
-            <text class="data-value">{{ deviceStatic.photo_fre }}/天</text>
+            <text class="data-value">{{ deviceStatic.photo_fre }}min/天</text>
             <text class="data-label">拍照上传频率</text>
             <text class="data-label">拍照上传频率</text>
           </view>
           </view>
           <view class="data-item">
           <view class="data-item">

+ 5 - 1
pages/sy/components/photoImage.vue

@@ -63,6 +63,10 @@ export default {
       type: String | Number,
       type: String | Number,
       default: ''
       default: ''
     },
     },
+    cmd:{
+      type: String,
+      default: ''
+    },
   },
   },
   data() {
   data() {
     return {
     return {
@@ -96,7 +100,7 @@ export default {
     },
     },
     handleClick(item) {
     handleClick(item) {
       uni.navigateTo({
       uni.navigateTo({
-        url: '/pages/sy/devicePhoto?device_id=' + item?.device_id + '&addtime=' + item?.addtime + '&img_id=' + item?.ids + '&id=' + this.deviceInfo.id + '&currentYear=' + this.currentYear+'&device_type_id='+this.device_type_id+'&cmd=sy1'
+        url: '/pages/sy/devicePhoto?device_id=' + item?.device_id + '&addtime=' + item?.addtime + '&img_id=' + item?.ids + '&id=' + this.deviceInfo.id + '&currentYear=' + this.currentYear+'&device_type_id='+this.device_type_id+'&cmd='+this.cmd
       })
       })
     }
     }
   },
   },

+ 3 - 0
pages/sy/detail.vue

@@ -97,6 +97,7 @@
             :pestList="pestList"
             :pestList="pestList"
             :device_type_id="deviceInfo.type_id"
             :device_type_id="deviceInfo.type_id"
             :disableShow="disableShow"
             :disableShow="disableShow"
+            :cmd="cmd"
             @changeTab="changeTab"
             @changeTab="changeTab"
             :currentYear="currentYear"
             :currentYear="currentYear"
             :deviceInfo="deviceInfo"
             :deviceInfo="deviceInfo"
@@ -183,11 +184,13 @@ export default {
       polylineList:[],
       polylineList:[],
       isShowPhoto:false,
       isShowPhoto:false,
       deviceHistoryList:[],
       deviceHistoryList:[],
+      cmd:'',
       deviceStatic:{}
       deviceStatic:{}
     }
     }
   },
   },
   onLoad(options){
   onLoad(options){
     this.deviceInfo = JSON.parse(options.info);
     this.deviceInfo = JSON.parse(options.info);
+    this.cmd = options.cmd;
     const newVal = this.deviceInfo;
     const newVal = this.deviceInfo;
     if (newVal.device_model == '11'){
     if (newVal.device_model == '11'){
       this.isShowPhoto = true
       this.isShowPhoto = true

+ 13 - 1
pages/sy/deviceControl.vue

@@ -13,7 +13,7 @@
     <view class="device-detail__body">
     <view class="device-detail__body">
       <view class="tabs">
       <view class="tabs">
         <view class="tab-container">
         <view class="tab-container">
-          <view class="tab-item" :class="activeTab === 'pestAnalysis'?'active':''" @click="handleTabClick('pestAnalysis')">
+          <view class="tab-item" v-if="myuser_type" :class="activeTab === 'pestAnalysis'?'active':''" @click="handleTabClick('pestAnalysis')">
             管理员
             管理员
           </view>
           </view>
           <view class="tab-item" :class="activeTab === 'viewImage'?'active':''" @click="handleTabClick('viewImage')">
           <view class="tab-item" :class="activeTab === 'viewImage'?'active':''" @click="handleTabClick('viewImage')">
@@ -163,6 +163,7 @@ export default {
       sliderField: '',
       sliderField: '',
       sliderMin: 0,
       sliderMin: 0,
       sliderMax: 100,
       sliderMax: 100,
+      myuser_type: false,
       sliderRect: null
       sliderRect: null
     }
     }
   },
   },
@@ -184,6 +185,17 @@ export default {
         label: j + ':00'
         label: j + ':00'
       })
       })
     }
     }
+    uni.getStorage({
+      key:"myuser_type",
+      success:(res)=>{
+        if(Number(res.data) == 1){
+          this.myuser_type = true
+          this.activeTab = 'pestAnalysis'
+        }else{
+          this.activeTab = 'viewImage'
+        }
+      }
+    })
     this.list2 = [time1, time2];
     this.list2 = [time1, time2];
     this.deviceType = options.device_type
     this.deviceType = options.device_type
     this.getControlDeviceConfigInfo()
     this.getControlDeviceConfigInfo()

+ 1 - 2
pages/sy/devicePhoto.vue

@@ -194,7 +194,6 @@ export default {
     this.addtime = addtime;
     this.addtime = addtime;
     this.device_type_id = device_type_id;
     this.device_type_id = device_type_id;
     this.time_begin = this.addtime;
     this.time_begin = this.addtime;
-    console.log(this.time_begin,'thistime_begin')
     this.defaultDate = this.addtime;
     this.defaultDate = this.addtime;
     this.time_end = this.addtime;
     this.time_end = this.addtime;
     this.selectorRange = [];
     this.selectorRange = [];
@@ -492,7 +491,7 @@ export default {
         // this.pestList = [];
         // this.pestList = [];
         const markers = [];
         const markers = [];
         // 根据原图宽度计算缩放比例
         // 根据原图宽度计算缩放比例
-        let scaleRatio = 3.1;
+        let scaleRatio = 3.06;
         // if (this.imageWidth >= 5000) {
         // if (this.imageWidth >= 5000) {
         //   scaleRatio = 4;
         //   scaleRatio = 4;
         // } else if (this.imageWidth >= 4000) {
         // } else if (this.imageWidth >= 4000) {

+ 2 - 2
util/api.js

@@ -9,10 +9,10 @@ export const myRequest = (options) => {
     //      ? 'https://uat.hnyfwlw.com'
     //      ? 'https://uat.hnyfwlw.com'
     //      : 'https://web.hnyfwlw.com';
     //      : 'https://web.hnyfwlw.com';
     // BASE_URL = 'http://192.168.1.107:8000'
     // BASE_URL = 'http://192.168.1.107:8000'
-    // BASE_URL = 'http://218.28.198.186:10508';
+    BASE_URL = 'http://218.28.198.186:10508';
     // BASE_URL = 'http://8.136.98.49:8002';
     // BASE_URL = 'http://8.136.98.49:8002';
   }
   }
-  BASE_URL = config.productAPI;
+  // BASE_URL = config.productAPI;
   // BASE_URL = config.developAPI;
   // BASE_URL = config.developAPI;
   var session_key = '';
   var session_key = '';
   session_key = uni.getStorageSync('session_key');
   session_key = uni.getStorageSync('session_key');