From cd8d5018368f739c6e63a5b16e5278033c766871 Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Tue, 6 May 2025 08:58:55 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ConfigMaterial/ConfigMaterialInfoList.vue | 67 +++++++++++++++---- 1 file changed, 54 insertions(+), 13 deletions(-) diff --git a/src/views/invoicing/ConfigMaterial/ConfigMaterialInfoList.vue b/src/views/invoicing/ConfigMaterial/ConfigMaterialInfoList.vue index f1af149..ccffc6b 100644 --- a/src/views/invoicing/ConfigMaterial/ConfigMaterialInfoList.vue +++ b/src/views/invoicing/ConfigMaterial/ConfigMaterialInfoList.vue @@ -59,16 +59,40 @@ -
- - - - +
+ + + + + + + + +
@@ -111,6 +135,7 @@ import type { TreeProps } from 'ant-design-vue'; import { DownOutlined } from '@ant-design/icons-vue'; import { defHttp } from '/@/utils/http/axios'; +import type { CollapseProps } from 'ant-design-vue'; const formRef = ref(); const queryParam = reactive({}); @@ -118,6 +143,11 @@ import { defHttp } from '/@/utils/http/axios'; const registerModal = ref(); const userStore = useUserStore(); let treeData = ref([]); + const activeKey = ref(0); + const activeKey2 = ref(0); + const rootSubmenuKeys= ['sub1'] + const openKeys= [] + const selectedKeys= [] //注册table数据 const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({ tableProps: { @@ -157,9 +187,20 @@ import { defHttp } from '/@/utils/http/axios'; sm: 20, }); - function onSelect(ids, e) { - let id = ids[0]; - queryParam.treeId =id; + function onOpenChange (openKeys: string[]){ + const latestOpenKey = openKeys.find(key => openKeys.indexOf(key) === -1); + if (rootSubmenuKeys.indexOf(latestOpenKey!) === -1) { + openKeys = openKeys; + } else { + openKeys = latestOpenKey ? [latestOpenKey] : []; + } + }; + + function onSelect({ key, domEvent }) { + // console.log(ids); + // console.log(e); + // let id = ids[0]; + queryParam.treeId =key; reload(); } /** From 4dd33cd28a9caba9c0ac5a7398e1e19ed0d9263e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E7=A3=8A?= <45566618@qq.com> Date: Tue, 6 May 2025 11:06:24 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E5=90=8C=E6=AD=A5tplink=E4=BB=A3=E7=A0=81?= =?UTF-8?q?=E4=B8=8E=E8=BF=90=E7=BB=B4=E4=BB=A3=E7=A0=81=E4=B8=80=E8=87=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/iot/tplink/project/ProjectInfo.data.ts | 4 ++-- src/views/iot/tplink/region/RegionInfo.api.ts | 2 +- src/views/iot/tplink/region/components/RegionForm.vue | 8 ++++---- .../iot/tplink/region/components/RegionInfoDrawer.vue | 8 ++++---- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/views/iot/tplink/project/ProjectInfo.data.ts b/src/views/iot/tplink/project/ProjectInfo.data.ts index b4cb545..f837301 100644 --- a/src/views/iot/tplink/project/ProjectInfo.data.ts +++ b/src/views/iot/tplink/project/ProjectInfo.data.ts @@ -59,7 +59,7 @@ export const searchFormSchema: FormSchema[] = [ field: 'institutionId', component: 'JDictSelectTag', componentProps: { - dictCode: 'nu_admin_institution_area,inst_name,id,org_category = 1 order by inst_name asc', + dictCode: 'sys_depart,depart_name,id,org_category = 1 order by depart_name asc', placeholder: '请选择机构', }, }, @@ -107,7 +107,7 @@ export const formSchema: FormSchema[] = [ field: 'institutionId', component: 'JDictSelectTag', componentProps: { - dictCode: 'nu_admin_institution_area,inst_name,id,org_category = 1 order by inst_name asc', + dictCode: 'sys_depart,depart_name,id,org_category = 1 order by depart_name asc', placeholder: '请选择机构', }, }, diff --git a/src/views/iot/tplink/region/RegionInfo.api.ts b/src/views/iot/tplink/region/RegionInfo.api.ts index 5c1eac3..dd74287 100644 --- a/src/views/iot/tplink/region/RegionInfo.api.ts +++ b/src/views/iot/tplink/region/RegionInfo.api.ts @@ -11,7 +11,7 @@ enum Api { add = '/iot/regionInfo/add', edit = '/iot/regionInfo/edit', delete = '/iot/regionInfo/delete', - queryChildrenByParentId = '/admin/institutionArea/queryChildrenByParentId', + queryChildrenByParentId = '/sys/sysDepart/queryChildrenByParentId', } diff --git a/src/views/iot/tplink/region/components/RegionForm.vue b/src/views/iot/tplink/region/components/RegionForm.vue index c80be9c..a4c3c9a 100644 --- a/src/views/iot/tplink/region/components/RegionForm.vue +++ b/src/views/iot/tplink/region/components/RegionForm.vue @@ -5,8 +5,8 @@ 请选择… @@ -103,9 +103,9 @@ async function handleChange(value,option:Option,formData){ if(value == null){ - formData["regionName"] = model.value["regionName"]; + formData["departName"] = model.value["departName"]; }else{ - formData["regionName"] = option.label; + formData["departName"] = option.label; } } diff --git a/src/views/iot/tplink/region/components/RegionInfoDrawer.vue b/src/views/iot/tplink/region/components/RegionInfoDrawer.vue index 78931b2..4e264fb 100644 --- a/src/views/iot/tplink/region/components/RegionInfoDrawer.vue +++ b/src/views/iot/tplink/region/components/RegionInfoDrawer.vue @@ -12,8 +12,8 @@