diff --git a/apps/web-antd/src/api/iot/thingmodel/index.ts b/apps/web-antd/src/api/iot/thingmodel/index.ts index 341e0964e..354088704 100644 --- a/apps/web-antd/src/api/iot/thingmodel/index.ts +++ b/apps/web-antd/src/api/iot/thingmodel/index.ts @@ -175,17 +175,27 @@ export function deleteThingModelList(ids: number[]) { }); } -/** 导入物模型 TSL */ +/** 获取物模型 TSL */ +export function getThingModelTSL(productId: number) { + return requestClient.get( + '/iot/thing-model/get-tsl', + { params: { productId } }, + ); +} + +/** 导入物模型 TSL export function importThingModelTSL(productId: number, tslData: any) { return requestClient.post('/iot/thing-model/import-tsl', { productId, tslData, }); } + */ -/** 导出物模型 TSL */ +/** 导出物模型 TSL export function exportThingModelTSL(productId: number) { return requestClient.get('/iot/thing-model/export-tsl', { params: { productId }, }); } + */ diff --git a/apps/web-antd/src/views/iot/alert/record/index.vue b/apps/web-antd/src/views/iot/alert/record/index.vue index 64ba6cfac..560aae39a 100644 --- a/apps/web-antd/src/views/iot/alert/record/index.vue +++ b/apps/web-antd/src/views/iot/alert/record/index.vue @@ -101,7 +101,7 @@ async function handleProcess(row: AlertRecord) { try { await processAlertRecord(row.id as number, processRemark); message.success('处理成功'); - handleRefresh(); + onRefresh(); } catch (error) { console.error('处理失败:', error); throw error; diff --git a/apps/web-antd/src/views/iot/device/device/data.ts b/apps/web-antd/src/views/iot/device/device/data.ts index e825055dc..86996ceae 100644 --- a/apps/web-antd/src/views/iot/device/device/data.ts +++ b/apps/web-antd/src/views/iot/device/device/data.ts @@ -113,16 +113,16 @@ export function useFormSchema(): VbenFormSchema[] { .optional() .or(z.literal('')), }, - // { - // fieldName: 'locationType', - // label: '定位类型', - // component: 'RadioGroup', - // componentProps: { - // options: getDictOptions(DICT_TYPE.IOT_LOCATION_TYPE, 'number'), - // buttonStyle: 'solid', - // optionType: 'button', - // }, - // }, + { + fieldName: 'locationType', + label: '定位类型', + component: 'RadioGroup', + componentProps: { + options: getDictOptions(DICT_TYPE.IOT_LOCATION_TYPE, 'number'), + buttonStyle: 'solid', + optionType: 'button', + }, + }, { fieldName: 'longitude', label: '设备经度', diff --git a/apps/web-antd/src/views/iot/device/device/modules/DeviceForm.vue b/apps/web-antd/src/views/iot/device/device/modules/DeviceForm.vue index 39fe16a99..32875e43f 100644 --- a/apps/web-antd/src/views/iot/device/device/modules/DeviceForm.vue +++ b/apps/web-antd/src/views/iot/device/device/modules/DeviceForm.vue @@ -1,13 +1,15 @@