diff --git a/src/components/AddPreSetting.vue b/src/components/AddPreSetting.vue index db56ca5..3438829 100644 --- a/src/components/AddPreSetting.vue +++ b/src/components/AddPreSetting.vue @@ -98,6 +98,20 @@ />

+
+

风机速度(%)

+

+ +

+

Log等级

@@ -217,6 +231,16 @@ :show="continued_humiShow" @blur="continued_humiShow = false" /> + { continued_satur: continued_satur.value, stoped_humi: stoped_humi.value, continued_humi: continued_humi.value, + draughtFanValue: draughtFanValue.value, } console.log(data) webSocketStore.sendCommandMsg(addFormulaJSON(data)) @@ -334,6 +361,7 @@ const hideClickKey = flag => { stoped_saturShow.value = false continued_saturShow.value = false max_humidityShow.value = false + draughtFanShow.value = false if (flag == 1) { addLiquidConfigValShow.value = true } @@ -364,6 +392,9 @@ const hideClickKey = flag => { if (flag == 10) { continued_humiShow.value = true } + if (flag == 12) { + draughtFanShow.value = true + } } const handleInput = (value, index) => { @@ -504,6 +535,27 @@ const formatter4 = value => { return value.replace(/^0+/gi, '') } +const formatter12 = value => { + if (parseInt(value) == 0) { + return '0' + } + let arr = settingStore.allSettingList.filter( + item => item.name == 'draughtFanValue', + ) + if (arr && arr.length > 0) { + if (parseInt(value) > arr[0].val_upper_limit) { + return arr[0].val_upper_limit + '' + } + if (parseInt(value) < arr[0].val_lower_limit) { + return arr[0].val_lower_limit + '' + } + } + if (value == '') { + return '0' + } + return value.replace(/^0+/gi, '') +} + const formatter5 = value => { if (parseInt(value) == 0) { return '0' @@ -702,6 +754,14 @@ const setcontinued_humiVal = () => { } } +const setDraughtFanValue = () => { + const val = parseInt(draughtFanValue.value) + if (isNaN(val)) { + showFailToast('设置失败,请填写正确参数') + return + } +} + const setSprayLiquidVal = () => { const val = parseInt(sprayLiquidConfigVal.value) if (isNaN(val)) { diff --git a/src/components/Setting/components/Device.vue b/src/components/Setting/components/Device.vue index 0a59dc3..643359e 100644 --- a/src/components/Setting/components/Device.vue +++ b/src/components/Setting/components/Device.vue @@ -120,7 +120,7 @@

-

风机速度

+

风机速度(%)