From 9896bc669eb6df5086d9ceded1b0b6dee05985a5 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 9 Mar 2023 09:39:13 +0800 Subject: [PATCH] =?UTF-8?q?gov/org/customeragency/agencylist=E8=BF=94?= =?UTF-8?q?=E5=9B=9EorgIdPath?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/dto/result/AgencyTreeResultDTO.java | 4 ++++ .../main/resources/mapper/CustomerAgencyDao.xml | 14 ++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/AgencyTreeResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/AgencyTreeResultDTO.java index 4d48b54960..ab12b7bac2 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/AgencyTreeResultDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/AgencyTreeResultDTO.java @@ -35,6 +35,10 @@ public class AgencyTreeResultDTO implements Serializable { * orgId-orgLevel */ private String orgLevel; + /** + * agencyId的全路径,包含自身 + */ + private String orgIdPath; /** * 下级机关组织 */ diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerAgencyDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerAgencyDao.xml index 269898b5fd..882249b1ad 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerAgencyDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerAgencyDao.xml @@ -622,7 +622,12 @@ ID AS agencyId, ORGANIZATION_NAME AS agencyName, PID, - LEVEL + LEVEL, + ( + case when pid is null or pid='0' or pid='' then id + else concat(pids,':',id) + end + )as orgIdPath from customer_agency where DEL_FLAG = 0 @@ -636,7 +641,12 @@ ID AS agencyId, ORGANIZATION_NAME AS agencyName, PID, - LEVEL + LEVEL, + ( + case when pid is null or pid='0' or pid='' then id + else concat(pids,':',id) + end + )as orgIdPath from customer_agency where