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 @@ + + + + + + + + + + + + + + + + + + + + {{ state.isExpand ? "折叠" : "展开" }} + + + + + + + + + + + + + + + + + + + + {{ node.label }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ 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 @@ - + @@ -14,6 +14,13 @@ {{ $t('common.resetBtn') }} + + + + 新 增 + + + @@ -37,6 +44,24 @@ + + + + + + + + + + + + + + 取消 + 确认 + + + + + \ No newline at end of file