Commit e8c18f448e40fc9353629e9efd0cc5bc2febe399

Authored by loveumiko
1 parent 130a9a8c

fix: 修改判断是不是TCP下面modBUS

@@ -37,7 +37,8 @@ @@ -37,7 +37,8 @@
37 const { name, detail, identifier, deviceDetail, extensionDesc } = record; 37 const { name, detail, identifier, deviceDetail, extensionDesc } = record;
38 const { dataType } = detail; 38 const { dataType } = detail;
39 const { type } = dataType || {}; 39 const { type } = dataType || {};
40 - const { codeType } = deviceDetail || {}; 40 + const { codeType, deviceProfile } = deviceDetail || {};
  41 + const { transportType } = deviceProfile || {};
41 const { registerAddress, actionType } = extensionDesc || {}; 42 const { registerAddress, actionType } = extensionDesc || {};
42 formField.value = identifier; 43 formField.value = identifier;
43 44
@@ -53,8 +54,8 @@ @@ -53,8 +54,8 @@
53 isShowActionType.value = actionType ? true : false; //判断modBUS类型时 物模型是否填写扩展描述 54 isShowActionType.value = actionType ? true : false; //判断modBUS类型时 物模型是否填写扩展描述
54 55
55 //是modBUS类型的就用另外的表单 56 //是modBUS类型的就用另外的表单
56 - //判断是否是modBus的下发命令  
57 - if (codeType == TaskTypeEnum.MODBUS) { 57 + //判断是否是TCP ==> modBus的下发命令
  58 + if (codeType == TaskTypeEnum.MODBUS && transportType == 'TCP') {
58 isShowModBUS.value = true; 59 isShowModBUS.value = true;
59 modBUSForm.value = { 60 modBUSForm.value = {
60 crc: 'CRC_16_LOWER', 61 crc: 'CRC_16_LOWER',