Commit 30f9ccff86099a47916a5d53f9d4e682c24c225b

Authored by loveumiko
1 parent 61c1e274

fix: 修改属性下发时deviceCode的取值

... ... @@ -167,6 +167,7 @@ export interface DeviceRecord {
167 167 creator: string;
168 168 createTime: string;
169 169 codeType?: string;
  170 + code?: string;
170 171 name: string;
171 172 tenantId: string;
172 173 transportType: string;
... ...
... ... @@ -39,10 +39,9 @@
39 39 const { name, detail, identifier, deviceDetail, extensionDesc } = record;
40 40 const { dataType } = detail;
41 41 const { type } = dataType || {};
42   - const { codeType, deviceProfile } = deviceDetail || {};
  42 + const { codeType, deviceProfile, code } = deviceDetail || {};
43 43 const { transportType } = deviceProfile || {};
44 44 const { registerAddress, actionType, zoomFactor } = extensionDesc || {}; //获取扩展描述内容
45   -
46 45 formField.value = identifier;
47 46 zoomFactorValue.value = zoomFactor ? Number(zoomFactor) : 1;
48 47 isShowMultiply.value = type == 'INT' || type == 'DOUBLE' ? true : false;
... ... @@ -64,7 +63,7 @@
64 63 isShowModBUS.value = true;
65 64 modBUSForm.value = {
66 65 crc: 'CRC_16_LOWER',
67   - deviceCode: '01',
  66 + deviceCode: code,
68 67 method: actionType == '16' ? '10' : actionType,
69 68 registerAddress,
70 69 registerNumber: 1,
... ...