From 3a46d3e97978feb0e35aa38835bdf53fcb99ec10 Mon Sep 17 00:00:00 2001 From: 100011797 <2642441182@qq.com> Date: Wed, 12 Jul 2023 20:56:13 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Collector/Point/Save/SaveModBus.vue | 9 ++- .../Collector/Point/Save/SaveOPCUA.vue | 2 +- .../Collector/Point/Scan/Table.vue | 8 ++- .../Point/components/BatchUpdate/index.vue | 3 +- .../DataCollect/Collector/Tree/index.vue | 2 + src/views/Northbound/DuerOS/index.vue | 5 +- .../components/ViewDialog.vue | 2 +- .../Detail/Running/Property/Detail/Charts.vue | 6 +- .../Detail/DeviceAccess/accessModal.vue | 68 ++++++++++--------- .../Configuration/Save/Scene/Save/index.vue | 2 +- .../NoticeRule/components/Detail/index.vue | 56 ++++++++++++--- 11 files changed, 105 insertions(+), 58 deletions(-) diff --git a/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue b/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue index b702dfa1..5ddbdfd5 100644 --- a/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue +++ b/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue @@ -58,7 +58,7 @@ placeholder="请输入地址" v-model:value="formData.pointKey" :min="0" - :max="999999999" + :max="999999" :precision="0" /> @@ -132,7 +132,7 @@ style="width: 100%" placeholder="请输入小数保留位数" :min="0" - :max="255" + :max="65535" :precision="0" v-model:value=" formData.configuration.codec.configuration.scale @@ -222,7 +222,7 @@ v-model:value="formData.configuration.interval" addon-after="ms" :max="2147483648" - :min="1" + :min="0" /> @@ -380,8 +380,7 @@ const changeWriteByteCount = (value: Array) => { formData.value.configuration.parameter.writeByteCount = value[0]; }; const changeFunction = (value: string) => { - formData.value.accessModes = - value === 'InputRegisters' ? ['read'] : ['read', 'write']; + formData.value.accessModes = ['InputRegisters', 'DiscreteInputs'].includes(value) ? ['read'] : ['read', 'write']; }; const checkProvider = (_rule: Rule, value: string): Promise => diff --git a/src/views/DataCollect/Collector/Point/Save/SaveOPCUA.vue b/src/views/DataCollect/Collector/Point/Save/SaveOPCUA.vue index 2fc4791e..b5539a02 100644 --- a/src/views/DataCollect/Collector/Point/Save/SaveOPCUA.vue +++ b/src/views/DataCollect/Collector/Point/Save/SaveOPCUA.vue @@ -59,7 +59,7 @@ v-model:value="formData.configuration.interval" addon-after="ms" :max="2147483648" - :min="1" + :min="0" /> diff --git a/src/views/DataCollect/Collector/Point/Scan/Table.vue b/src/views/DataCollect/Collector/Point/Scan/Table.vue index 76160745..b2826b2f 100644 --- a/src/views/DataCollect/Collector/Point/Scan/Table.vue +++ b/src/views/DataCollect/Collector/Point/Scan/Table.vue @@ -111,6 +111,10 @@ 'value', ]" :rules="[ + { + required: true, + message: '请输入', + }, { pattern: regOnlyNumber, message: '请输入0或者正整数', @@ -126,7 +130,7 @@ allowClear addon-after="ms" :max="2147483647" - :min="1" + :min="0" :disabled=" index !== 0 && record.configuration[dataIndex].check @@ -229,7 +233,7 @@ const checkLength = (_rule: Rule, value: string): Promise => ? reject('最多可输入64个字符') : resolve(''); } else { - reject('请输入'); + resolve('') } }); diff --git a/src/views/DataCollect/Collector/Point/components/BatchUpdate/index.vue b/src/views/DataCollect/Collector/Point/components/BatchUpdate/index.vue index 66fd57b5..02b7f3ec 100644 --- a/src/views/DataCollect/Collector/Point/components/BatchUpdate/index.vue +++ b/src/views/DataCollect/Collector/Point/components/BatchUpdate/index.vue @@ -55,7 +55,8 @@ v-model:value="formData.interval" addon-after="ms" :max="2147483648" - :min="1" + :min="0" + :precision="0" /> diff --git a/src/views/DataCollect/Collector/Tree/index.vue b/src/views/DataCollect/Collector/Tree/index.vue index 48929200..2672937b 100644 --- a/src/views/DataCollect/Collector/Tree/index.vue +++ b/src/views/DataCollect/Collector/Tree/index.vue @@ -190,6 +190,8 @@ const handlUpdate = async (data: any) => { }); if (resp.status === 200) { handleSearch(params.value); + const _item = collectorAll.value.find((i: any) => i?.id === selectedKeys.value?.[0]) + emits('change', _item) onlyMessage('操作成功', 'success'); } }; diff --git a/src/views/Northbound/DuerOS/index.vue b/src/views/Northbound/DuerOS/index.vue index 8bf2ce8c..61e0fbff 100644 --- a/src/views/Northbound/DuerOS/index.vue +++ b/src/views/Northbound/DuerOS/index.vue @@ -146,13 +146,13 @@ import { _undeploy, _deploy, _delete, - queryProductList, queryTypes, } from '@/api/northbound/dueros'; import type { ActionsType } from '@/views/device/Instance/typings'; import { getImage, onlyMessage } from '@/utils/comm'; import { useMenuStore } from 'store/menu'; import BadgeStatus from '@/components/BadgeStatus/index.vue'; +import { queryNoPagingPost } from '@/api/device/product'; const instanceRef = ref>({}); const params = ref>({}); @@ -174,9 +174,10 @@ const columns = [ key: 'productName', search: { type: 'select', + rename: 'id', options: () => new Promise((resolve) => { - queryProductList().then((resp: any) => { + queryNoPagingPost({}).then((resp: any) => { resolve( resp.result.map((item: any) => ({ label: item.name, diff --git a/src/views/account/Center/components/StationMessage/components/NotificationRecord/components/ViewDialog.vue b/src/views/account/Center/components/StationMessage/components/NotificationRecord/components/ViewDialog.vue index 2fda0c2b..114dc1c7 100644 --- a/src/views/account/Center/components/StationMessage/components/NotificationRecord/components/ViewDialog.vue +++ b/src/views/account/Center/components/StationMessage/components/NotificationRecord/components/ViewDialog.vue @@ -61,7 +61,7 @@
通知流水:
- +
diff --git a/src/views/device/Instance/Detail/Running/Property/Detail/Charts.vue b/src/views/device/Instance/Detail/Running/Property/Detail/Charts.vue index 88bd55db..43c87fb6 100644 --- a/src/views/device/Instance/Detail/Running/Property/Detail/Charts.vue +++ b/src/views/device/Instance/Detail/Running/Property/Detail/Charts.vue @@ -199,9 +199,9 @@ const getOptions = (arr: any[]) => { }; watch( - () => [cycle, agg], - ([newCycle, newAgg]) => { - if (newCycle.value === '*' && _type.value) { + () => [cycle.value, agg.value, prop.time], + ([newCycle]) => { + if (newCycle === '*' && _type.value) { queryChartsList(); } else { queryChartsAggList(); diff --git a/src/views/device/Product/Detail/DeviceAccess/accessModal.vue b/src/views/device/Product/Detail/DeviceAccess/accessModal.vue index 3f462490..41d325c9 100644 --- a/src/views/device/Product/Detail/DeviceAccess/accessModal.vue +++ b/src/views/device/Product/Detail/DeviceAccess/accessModal.vue @@ -66,42 +66,44 @@ {{ slotProps.name }} - - -
- {{ slotProps.channelInfo?.name }} -
- -
+
+ + +
+ {{ slotProps.channelInfo?.name }} +
+ +
+ {{ + slotProps.channelInfo?.addresses + ? slotProps.channelInfo + ?.addresses[0].address + : '' + }} +
+
+
+ +
协议
+
{{ slotProps.protocolDetail?.name }}
+
+
+ + + +
{{ - slotProps.channelInfo?.addresses - ? slotProps.channelInfo - ?.addresses[0].address - : '' + getDescription( + slotProps, + ) }}
-
-
- -
协议
-
{{ slotProps.protocolDetail?.name }}
-
-
- - - -
- {{ - getDescription( - slotProps, - ) - }} -
-
-
-
+ + + +
diff --git a/src/views/rule-engine/Alarm/Configuration/Save/Scene/Save/index.vue b/src/views/rule-engine/Alarm/Configuration/Save/Scene/Save/index.vue index 5609dcf4..f0aacb72 100644 --- a/src/views/rule-engine/Alarm/Configuration/Save/Scene/Save/index.vue +++ b/src/views/rule-engine/Alarm/Configuration/Save/Scene/Save/index.vue @@ -87,7 +87,7 @@ import { bindScene } from '@/api/rule-engine/configuration'; import { getImage, onlyMessage } from '@/utils/comm'; const columns = [ { - title: '名称', + title: '场景名称', dataIndex: 'name', key: 'name', search: { diff --git a/src/views/system/NoticeRule/components/Detail/index.vue b/src/views/system/NoticeRule/components/Detail/index.vue index cfce7d5a..13adfef9 100644 --- a/src/views/system/NoticeRule/components/Detail/index.vue +++ b/src/views/system/NoticeRule/components/Detail/index.vue @@ -15,19 +15,27 @@
通知模板
-
{{ obj.template }}
+
+ {{ obj.template }} +
模版内容
-
{{ obj.content }}
+
+ {{ obj.content }} +
模板变量
-
{{ variables }}
+
+ {{ variables }} +
用户权限
-
{{ obj.role }}
+
+ {{ obj.role }} +