diff --git a/src/utils/consts.ts b/src/utils/consts.ts index d4404334..555c55ef 100644 --- a/src/utils/consts.ts +++ b/src/utils/consts.ts @@ -55,5 +55,5 @@ export const USER_CENTER_MENU_BUTTON_CODE = 'user-center-passwd-update' export const protocolList = [ { label: 'OPC-UA', value: 'OPC_UA', alias: 'opc-ua' }, { label: 'Modbus/TCP', value: 'MODBUS_TCP', alias: 'modbus-tcp' }, - { label: 'GATEWAY', value: 'GATEWAY', alias: 'collector-gateway' }, + { label: 'GATEWAY', value: 'COLLECTOR_GATEWAY', alias: 'collector-gateway' }, ] diff --git a/src/views/DataCollect/Channel/Save/index.vue b/src/views/DataCollect/Channel/Save/index.vue index 545281c8..cfccd740 100644 --- a/src/views/DataCollect/Channel/Save/index.vue +++ b/src/views/DataCollect/Channel/Save/index.vue @@ -93,7 +93,7 @@ /> (cloneDeep(FormState)); const handleOk = async () => { const params: any = await formRef.value?.validate(); - if (params?.provider === 'GATEWAY') { + if (params?.provider === 'COLLECTOR_GATEWAY') { params.configuration.deviceName = formData.value.configuration.deviceName } diff --git a/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue b/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue index 9d40ba15..20beddc7 100644 --- a/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue +++ b/src/views/DataCollect/Collector/Point/Save/SaveModBus.vue @@ -347,7 +347,7 @@ const handleOk = async () => { address: data?.pointKey, }; - if (props.data.provider === 'GATEWAY') { + if (props.data.provider === 'COLLECTOR_GATEWAY') { const configuration = cloneDeep(params.configuration) params.configuration = { configuration: configuration, @@ -447,12 +447,12 @@ watch( watch( () => props.data, (value) => { - if (value.id && ['MODBUS_TCP', 'GATEWAY'].includes(value.provider)) { + if (value.id && ['MODBUS_TCP', 'COLLECTOR_GATEWAY'].includes(value.provider)) { const _value: any = cloneDeep(value); const { writeByteCount, byteCount } = - props.data.provider === 'GATEWAY' ? _value.configuration.configuration.parameter: _value.configuration.parameter; + props.data.provider === 'COLLECTOR_GATEWAY' ? _value.configuration.configuration.parameter: _value.configuration.parameter; - if (props.data.provider === 'GATEWAY') { + if (props.data.provider === 'COLLECTOR_GATEWAY') { formData.value = { ...omit(_value, ['configuration']), ..._value.configuration, diff --git a/src/views/DataCollect/Collector/Point/index.vue b/src/views/DataCollect/Collector/Point/index.vue index e05c3d0a..28a3b1c6 100644 --- a/src/views/DataCollect/Collector/Point/index.vue +++ b/src/views/DataCollect/Collector/Point/index.vue @@ -20,7 +20,7 @@