Ver código fonte

feat(设备控制): 添加存储间隔和数据传输间隔变更事件处理

添加 changeStorageVal 和 changeDataInterval 方法,用于处理滑块值变更事件
allen 1 semana atrás
pai
commit
23a214cc73
1 arquivos alterados com 10 adições e 0 exclusões
  1. 10 0
      pages/deviceDetails/weatherStation/devControl.vue

+ 10 - 0
pages/deviceDetails/weatherStation/devControl.vue

@@ -18,6 +18,7 @@
           show-value="true"
           :min="1"
           :max="240"
+          @change="changeStorageVal"
           block-color="#57C878"
           activeColor="#57C878"
           step="1"
@@ -30,6 +31,7 @@
           show-value="true"
           :min="1"
           :max="240"
+          @change="changeDataInterval"
           block-color="#57C878"
           activeColor="#57C878"
           step="1"
@@ -59,6 +61,14 @@ export default {
     };
   },
   methods: {
+    // 改变本地存储间隔
+    changeStorageVal(e) {
+      this.storageVal = e.detail.value
+    },
+    // 改变数据传输间隔
+    changeDataInterval(e) {
+      this.dataInterval = e.detail.value
+    },
     // 获取设备控制参数信息
     async getDevControlParams() {
       this.loading = true