From 67a2417384fc6052ade068e79b3c6a9f81f5e615 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E6=9B=B9=E7=A3=8A?= <45566618@qq.com>
Date: Fri, 21 Mar 2025 15:10:58 +0800
Subject: [PATCH] =?UTF-8?q?tplink=E6=91=84=E5=83=8F=E5=A4=B4=E5=8C=BA?=
=?UTF-8?q?=E5=9F=9F=E4=BF=A1=E6=81=AF=E4=BC=98=E5=8C=963?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/iot/tplink/region/RegionInfo.api.ts | 7 +-
.../iot/tplink/region/RegionInfo.data.ts | 8 +-
.../region/components/RegionLeftTree.vue | 169 ++++++++++++++++--
3 files changed, 166 insertions(+), 18 deletions(-)
diff --git a/src/views/iot/tplink/region/RegionInfo.api.ts b/src/views/iot/tplink/region/RegionInfo.api.ts
index 86465eb..90b396d 100644
--- a/src/views/iot/tplink/region/RegionInfo.api.ts
+++ b/src/views/iot/tplink/region/RegionInfo.api.ts
@@ -36,8 +36,13 @@ export const syncProject = (params?) => defHttp.get({ url: Api.syncProject, para
* 同步区域
* @param params
*/
-export const syncRegion = (params?) => defHttp.get({ url: Api.syncRegion, params });
+export const syncRegionChildren = (params?) => defHttp.get({ url: Api.syncRegionChildren, params });
+/**
+ * 同步子区域
+ * @param params
+ */
+export const syncRegion = (params?) => defHttp.get({ url: Api.syncRegion, params });
/**
* 列表接口
diff --git a/src/views/iot/tplink/region/RegionInfo.data.ts b/src/views/iot/tplink/region/RegionInfo.data.ts
index dea876c..2d62dcb 100644
--- a/src/views/iot/tplink/region/RegionInfo.data.ts
+++ b/src/views/iot/tplink/region/RegionInfo.data.ts
@@ -94,13 +94,7 @@ export const formSchema: FormSchema[] = [
label: '上级名称',
field: 'parentName',
component: 'Input',
- dynamicDisabled: ({model})=>{
- if(model.regionId || model.parentId){
- return true;
- }else{
- return false;
- }
- }
+ dynamicDisabled: true
},
{
label: '机构名称',
diff --git a/src/views/iot/tplink/region/components/RegionLeftTree.vue b/src/views/iot/tplink/region/components/RegionLeftTree.vue
index a9c01fb..39dfc23 100644
--- a/src/views/iot/tplink/region/components/RegionLeftTree.vue
+++ b/src/views/iot/tplink/region/components/RegionLeftTree.vue
@@ -3,16 +3,16 @@
刷新
-
新增
+
新增
同步
-
新增下级
+
新增下级
同步下级
-
+
+
+
+ {{ title }}
+
+
+ 添加子级
+
+ 删除
+
+
+
+
+
+
+
+