From ad2d4123734ece128a55270a00e2bc7d17038f9d Mon Sep 17 00:00:00 2001 From: ChenYi <296215406@outlook.com> Date: Thu, 11 Jun 2026 17:19:25 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E5=96=84=E8=AE=BE=E5=A4=87=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E9=80=BB=E8=BE=91=EF=BC=8C=E6=96=B0=E5=A2=9E=E9=89=B4?= =?UTF-8?q?=E6=9D=83=E6=A8=A1=E5=BC=8F=E9=80=89=E6=8B=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/web-antd/src/api-client/schemas.gen.ts | 6 ++ apps/web-antd/src/api-client/types.gen.ts | 2 + .../web-antd/src/locales/langs/en-US/abp.json | 3 +- .../web-antd/src/locales/langs/zh-CN/abp.json | 3 +- .../devicemanagement/deviceinfo/index.vue | 16 ++++ .../devicemanagement/deviceinfo/schema.ts | 76 +++++++++++++++++++ 6 files changed, 104 insertions(+), 2 deletions(-) diff --git a/apps/web-antd/src/api-client/schemas.gen.ts b/apps/web-antd/src/api-client/schemas.gen.ts index 4b41c25..5c73148 100644 --- a/apps/web-antd/src/api-client/schemas.gen.ts +++ b/apps/web-antd/src/api-client/schemas.gen.ts @@ -497,6 +497,9 @@ export const BatchCreateDeviceAggregationInputSchema = { }, deviceType: { '$ref': '#/components/schemas/DeviceTypeEnum' + }, + encryptionType: { + '$ref': '#/components/schemas/DeviceAuthenticationModeEnum' } }, additionalProperties: false, @@ -1528,6 +1531,9 @@ export const CreateDeviceAggregationInputSchema = { }, deviceType: { '$ref': '#/components/schemas/DeviceTypeEnum' + }, + encryptionType: { + '$ref': '#/components/schemas/DeviceAuthenticationModeEnum' } }, additionalProperties: false, diff --git a/apps/web-antd/src/api-client/types.gen.ts b/apps/web-antd/src/api-client/types.gen.ts index 3b35336..381502e 100644 --- a/apps/web-antd/src/api-client/types.gen.ts +++ b/apps/web-antd/src/api-client/types.gen.ts @@ -191,6 +191,7 @@ export type BatchCreateDeviceAggregationInput = { ioTPlatformProductId: string; deviceSourceType?: DeviceSourceTypeEnum; deviceType?: DeviceTypeEnum; + encryptionType?: DeviceAuthenticationModeEnum; }; /** @@ -407,6 +408,7 @@ export type CreateDeviceAggregationInput = { ioTPlatformProductId: string; deviceSourceType?: DeviceSourceTypeEnum; deviceType?: DeviceTypeEnum; + encryptionType?: DeviceAuthenticationModeEnum; }; /** diff --git a/apps/web-antd/src/locales/langs/en-US/abp.json b/apps/web-antd/src/locales/langs/en-US/abp.json index b12db92..8ccd7e0 100644 --- a/apps/web-antd/src/locales/langs/en-US/abp.json +++ b/apps/web-antd/src/locales/langs/en-US/abp.json @@ -223,7 +223,8 @@ "readingMode": "ReadingMode", "deviceType": "DeviceType", "deviceThingModelName": "ThingModelInfoManage", - "lifeInfoName": "Life Cycle" + "lifeInfoName": "Life Cycle", + "encryptionType": "Authentication Mode" }, "thingModelInfos": { "FiledType": "FiledType", diff --git a/apps/web-antd/src/locales/langs/zh-CN/abp.json b/apps/web-antd/src/locales/langs/zh-CN/abp.json index e4aa1f1..74dadac 100644 --- a/apps/web-antd/src/locales/langs/zh-CN/abp.json +++ b/apps/web-antd/src/locales/langs/zh-CN/abp.json @@ -216,7 +216,8 @@ "deviceType": "设备类型", "readingMode": "抄读模式", "deviceThingModelName": "设备物模型名称", - "lifeInfoName": "生命周期" + "lifeInfoName": "生命周期", + "encryptionType": "设备鉴权模式" }, "thingModelInfos": { "FiledType": "物模型类型", diff --git a/apps/web-antd/src/views/devicemanagement/deviceinfo/index.vue b/apps/web-antd/src/views/devicemanagement/deviceinfo/index.vue index 4b9918e..df21ebe 100644 --- a/apps/web-antd/src/views/devicemanagement/deviceinfo/index.vue +++ b/apps/web-antd/src/views/devicemanagement/deviceinfo/index.vue @@ -330,6 +330,15 @@ function setDeviceLifeInfo(row: Record, lifeInfo: number) { row.lifeInfo = lifeInfo; } +function getEncryptionTypeTagColor(encryptionType: unknown): string { + const type = Number(encryptionType); + if (type === 1) return 'blue'; + if (type === 2) return 'green'; + if (encryptionType === 'PerProductTypeSecret') return 'blue'; + if (encryptionType === 'PerDeviceSecret') return 'green'; + return 'default'; +} + // 设备升级相关 const upgradeRow: Record = ref({}); @@ -2599,6 +2608,7 @@ async function submitBatchAdd() { addressList, ioTPlatform: formValues.ioTPlatform, ioTPlatformProductId, + EncryptionType: formValues.EncryptionType, }; try { @@ -2997,6 +3007,12 @@ const toolbarActions = computed(() => [ ) " /> +