From cf647a65fc477af3fcaf8b8119f1343fd66b911b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E7=A3=8A?= <45566618@qq.com> Date: Tue, 5 Aug 2025 17:42:55 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=B5=E8=A1=A8=E5=90=8C=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../electricity/components/BusinessTable.vue | 214 +++++++ .../electricity/components/SelectNuList.vue | 123 ++++ .../electricity/components/SelectNuModal.vue | 70 +++ .../electricity/components/SelectedTable.vue | 147 +++++ .../tq/electricity/components/SourceTable.vue | 209 +++++++ .../tq/electricity/components/SyncLogList.vue | 125 ++++ .../iotsync/tq/electricity/electricity.api.ts | 49 ++ .../tq/electricity/electricity.data.ts | 223 +++++++ src/views/iotsync/tq/electricity/index.vue | 561 ++++++++++++++++++ 9 files changed, 1721 insertions(+) create mode 100644 src/views/iotsync/tq/electricity/components/BusinessTable.vue create mode 100644 src/views/iotsync/tq/electricity/components/SelectNuList.vue create mode 100644 src/views/iotsync/tq/electricity/components/SelectNuModal.vue create mode 100644 src/views/iotsync/tq/electricity/components/SelectedTable.vue create mode 100644 src/views/iotsync/tq/electricity/components/SourceTable.vue create mode 100644 src/views/iotsync/tq/electricity/components/SyncLogList.vue create mode 100644 src/views/iotsync/tq/electricity/electricity.api.ts create mode 100644 src/views/iotsync/tq/electricity/electricity.data.ts create mode 100644 src/views/iotsync/tq/electricity/index.vue diff --git a/src/views/iotsync/tq/electricity/components/BusinessTable.vue b/src/views/iotsync/tq/electricity/components/BusinessTable.vue new file mode 100644 index 0000000..e013d1b --- /dev/null +++ b/src/views/iotsync/tq/electricity/components/BusinessTable.vue @@ -0,0 +1,214 @@ + + + + + diff --git a/src/views/iotsync/tq/electricity/components/SelectNuList.vue b/src/views/iotsync/tq/electricity/components/SelectNuList.vue new file mode 100644 index 0000000..881a191 --- /dev/null +++ b/src/views/iotsync/tq/electricity/components/SelectNuList.vue @@ -0,0 +1,123 @@ + + + + + diff --git a/src/views/iotsync/tq/electricity/components/SelectNuModal.vue b/src/views/iotsync/tq/electricity/components/SelectNuModal.vue new file mode 100644 index 0000000..ceea225 --- /dev/null +++ b/src/views/iotsync/tq/electricity/components/SelectNuModal.vue @@ -0,0 +1,70 @@ + + + + + + diff --git a/src/views/iotsync/tq/electricity/components/SelectedTable.vue b/src/views/iotsync/tq/electricity/components/SelectedTable.vue new file mode 100644 index 0000000..1a5e739 --- /dev/null +++ b/src/views/iotsync/tq/electricity/components/SelectedTable.vue @@ -0,0 +1,147 @@ + + + + + diff --git a/src/views/iotsync/tq/electricity/components/SourceTable.vue b/src/views/iotsync/tq/electricity/components/SourceTable.vue new file mode 100644 index 0000000..025d9d6 --- /dev/null +++ b/src/views/iotsync/tq/electricity/components/SourceTable.vue @@ -0,0 +1,209 @@ + + + + + diff --git a/src/views/iotsync/tq/electricity/components/SyncLogList.vue b/src/views/iotsync/tq/electricity/components/SyncLogList.vue new file mode 100644 index 0000000..447c839 --- /dev/null +++ b/src/views/iotsync/tq/electricity/components/SyncLogList.vue @@ -0,0 +1,125 @@ + + + + + diff --git a/src/views/iotsync/tq/electricity/electricity.api.ts b/src/views/iotsync/tq/electricity/electricity.api.ts new file mode 100644 index 0000000..e14cfa4 --- /dev/null +++ b/src/views/iotsync/tq/electricity/electricity.api.ts @@ -0,0 +1,49 @@ +import { defHttp } from '/@/utils/http/axios'; + +enum Api { + sourceList = '/iot/tq/electricityMeter/sourceList', + departList = '/iot/tq/electricityMeter/departList', + nuList = '/iot/tq/electricityMeter/nuList', + businessList = '/iot/tq/electricityMeter/businessList', + nuSyncList = '/iot/tq/electricityMeter/nuSyncList', + syncDevices = '/iot/tq/electricityMeter/syncDevices', + syncLogList = '/iot/tq/electricityMeter/syncLogList', +} + +/** + * 列表接口 + * @param params + */ +export const sourceListApi = (params) => defHttp.get({ url: Api.sourceList, params }); +/** + * 列表接口 + * @param params + */ +export const departListApi = (params) => defHttp.get({ url: Api.departList, params }); +/** + * 列表接口 + * @param params + */ +export const nuListApi = (params) => defHttp.get({ url: Api.nuList, params }); +/** + * 列表接口 + * @param params + */ +export const businessListApi = (params) => defHttp.get({ url: Api.businessList, params }); +/** + * 列表接口 + * @param params + */ +export const nuSyncListApi = (params) => defHttp.get({ url: Api.nuSyncList, params }); +/** + * 同步设备 + * @param params + */ +export const syncDevicesApi = (params) => { + return defHttp.post({ url: Api.syncDevices, params }); +} +/** + * 列表接口 + * @param params + */ +export const syncLogListApi = (params) => defHttp.get({ url: Api.syncLogList, params }); diff --git a/src/views/iotsync/tq/electricity/electricity.data.ts b/src/views/iotsync/tq/electricity/electricity.data.ts new file mode 100644 index 0000000..377878a --- /dev/null +++ b/src/views/iotsync/tq/electricity/electricity.data.ts @@ -0,0 +1,223 @@ +import {BasicColumn, FormSchema} from '/@/components/Table'; + +export const businessColumns: BasicColumn[] = [ + { + title: 'SN', + align: 'center', + dataIndex: 'address', + width: 140, + }, + { + title: '区域编码', + align: "center", + dataIndex: 'nuId', + resizable: true, + }, + { + title: '区域名称', + align: "center", + dataIndex: 'nuName', + resizable: true, + }, + { + title: '区域标签', + align: "center", + dataIndex: 'areaFlag_dictText', + resizable: true, + } +]; + +//列表数据 +export const unselectedSourceColumns: BasicColumn[] = [ + { + title: 'SN', + align: 'center', + dataIndex: 'address', + width: 140, + }, +]; + +//列表数据 +export const selectedSourceColumns: BasicColumn[] = [ + { + title: 'SN', + align: 'center', + dataIndex: 'address', + width: 140, + }, + { + title: '机构', + align: "center", + dataIndex: 'departName', + resizable: true, + }, + { + title: '区域编码', + align: "center", + dataIndex: 'nuId', + resizable: true, + }, + { + title: '区域名称', + align: "center", + dataIndex: 'nuName', + resizable: true, + }, + { + title: '区域标签', + align: "center", + dataIndex: 'areaFlag_dictText', + resizable: true, + }, +]; + +export const nusColumns: BasicColumn[] = [ + { + title: '区域编码', + align: "center", + dataIndex: 'nuId', + resizable: true, + }, + { + title: '区域名称', + align: "center", + dataIndex: 'nuName', + resizable: true, + }, + { + title: '区域标签', + align: "center", + dataIndex: 'areaFlag_dictText', + resizable: true, + }, + { + title: '绑定设备数量', + align: "center", + dataIndex: 'deviceNum' + } +]; + +export const nuFormSchema: FormSchema[] = [ + { + label: '区域标签', + field: 'areaFlag', + component: 'JDictSelectTag', + componentProps: { + dictCode: 'nu_type', + }, + colProps: { span: 6 }, + }, +]; + + +export const selectedColumns: BasicColumn[] = [ + { + title: 'SN', + align: 'center', + dataIndex: 'address', + width: 140, + }, + { + title: '操作区域', + align: 'center', + dataIndex: 'dataTypeText', + width: 80, + }, + { + title: '操作类型', + align: 'center', + dataIndex: 'actionType', + width: 80, + }, + { + title: '区域编码', + align: "center", + dataIndex: 'nuId', + resizable: true, + }, + { + title: '区域名称', + align: "center", + dataIndex: 'nuName', + resizable: true, + }, + { + title: '区域标签', + align: "center", + dataIndex: 'areaFlag_dictText', + resizable: true, + } +]; + +export const asyncMaincolumns: BasicColumn[] = [ + { + title: 'SN', + align: 'center', + dataIndex: 'sn', + }, + { + title: '设备名称', + align: "center", + dataIndex: 'deviceName', + }, + { + title: '设备类型', + align: "center", + dataIndex: 'serverType', + }, + { + title: '同步时间', + align: "center", + dataIndex: 'createTime', + } +]; + +export const asyncSeedColumns: BasicColumn[] = [ + { + title: '同步类型', + align: "center", + dataIndex: 'syncType', + }, + { + title: '同步状态', + align: "center", + dataIndex: 'status', + }, + { + title: '同步时间', + align: "center", + dataIndex: 'createTime', + }, + { + title: '现机构', + align: "center", + dataIndex: 'departName', + }, + { + title: '现区域', + align: "center", + dataIndex: 'nuId', + }, + { + title: '原机构', + align: "center", + dataIndex: 'oldDepartName', + }, + { + title: '原区域', + align: "center", + dataIndex: 'oldNuId', + }, +]; + +export const logFormSchema: FormSchema[] = [ + { + label: 'SN', + field: 'sn', + component: 'Input', + componentProps: { + placeholder: '请输入SN', + }, + // colProps: { span: 6 }, + }, +]; diff --git a/src/views/iotsync/tq/electricity/index.vue b/src/views/iotsync/tq/electricity/index.vue new file mode 100644 index 0000000..7fd6d54 --- /dev/null +++ b/src/views/iotsync/tq/electricity/index.vue @@ -0,0 +1,561 @@ + + + + +