From f5e1d632040993c86558ce4856fc792daef18b0c Mon Sep 17 00:00:00 2001 From: dzc <2388224167@qq.com> Date: Thu, 21 Aug 2025 16:14:14 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E8=AE=BE=E5=A4=87=E5=88=86=E7=BB=84?= =?UTF-8?q?=E3=80=81=E8=AE=BE=E5=A4=87=E5=88=86=E7=BB=84=E6=9F=A5=E7=9C=8B?= =?UTF-8?q?=E7=9B=91=E6=8E=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/device/deviceGroup.ts | 23 ++ src/components/DraggableDeviceGroup/index.vue | 268 ++++++++++++++++++ src/components/index.ts | 2 + .../deviceGroup/camera-table-dialog.vue | 72 ++++- src/views/device/deviceGroup/index.vue | 26 +- src/views/device/deviceGroupPlay/index.vue | 200 +++++++++++++ 6 files changed, 578 insertions(+), 13 deletions(-) create mode 100644 src/components/DraggableDeviceGroup/index.vue create mode 100644 src/views/device/deviceGroupPlay/index.vue diff --git a/src/api/device/deviceGroup.ts b/src/api/device/deviceGroup.ts index 65bd6a2..f029b0e 100644 --- a/src/api/device/deviceGroup.ts +++ b/src/api/device/deviceGroup.ts @@ -1,5 +1,28 @@ import request from "/@/utils/request" +/** + * 房屋设施分组树 + */ +export function getDeviceGroupTree(params: any) { + return request({ + url: '/admin/device/deviceGroup/getDeviceGroupTree', + method: 'get', + params: params + }) +} + + +/** + * 添加设施分组子项 + */ +export function createGroupItem(data: any) { + return request({ + url: '/admin/device/deviceGroup/createGroupItem', + method: 'post', + data: data + }) +} + /** * 删除设施分组子项 */ diff --git a/src/components/DraggableDeviceGroup/index.vue b/src/components/DraggableDeviceGroup/index.vue new file mode 100644 index 0000000..5c0647c --- /dev/null +++ b/src/components/DraggableDeviceGroup/index.vue @@ -0,0 +1,268 @@ + + + + + \ No newline at end of file diff --git a/src/components/index.ts b/src/components/index.ts index 0ece2ba..d8642da 100644 --- a/src/components/index.ts +++ b/src/components/index.ts @@ -14,6 +14,7 @@ import Sign from '/@/components/Sign/index.vue'; import ChinaArea from '/@/components/ChinaArea/index.vue'; import OrgSelector from '/@/components/OrgSelector/index.vue'; import DraggableOrgTree from "/@/components/DraggableOrgTree/index.vue" +import DraggableDeviceGroup from "/@/components/DraggableDeviceGroup/index.vue" import PreviewImage from "/@/components/PreviewImage/index.vue" @@ -73,6 +74,7 @@ export default { app.component('PreviewImage', PreviewImage) app.component('DraggableOrgTree', DraggableOrgTree) + app.component('DraggableDeviceGroup', DraggableDeviceGroup) app.component('TagOnline', TagOnline); app.component('TagSex', TagSex); diff --git a/src/views/device/deviceGroup/camera-table-dialog.vue b/src/views/device/deviceGroup/camera-table-dialog.vue index f6fea45..d5f9213 100644 --- a/src/views/device/deviceGroup/camera-table-dialog.vue +++ b/src/views/device/deviceGroup/camera-table-dialog.vue @@ -1,5 +1,5 @@ + + \ No newline at end of file