From 31ab137195daa9f84bdf95656287ef67878b8810 Mon Sep 17 00:00:00 2001 From: Chengliang <1546584672@qq.com> Date: Tue, 30 Aug 2022 11:40:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BB=84=E7=BB=87=E6=9E=B6?= =?UTF-8?q?=E6=9E=84=E5=9B=BE=E8=B7=B3=E8=BD=AC=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/OrgChartServiceImpl.java | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/com/engine/organization/service/impl/OrgChartServiceImpl.java b/src/com/engine/organization/service/impl/OrgChartServiceImpl.java index a8488b13..a75ed3b5 100644 --- a/src/com/engine/organization/service/impl/OrgChartServiceImpl.java +++ b/src/com/engine/organization/service/impl/OrgChartServiceImpl.java @@ -144,7 +144,7 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { } private void findCompanyItemByParantId(String id, int currentLevel, String level, RecordSet rs, List> list, String whereSql, boolean expand) { - rs.executeQuery("select id, fname, ftype, fparentid, fnumber from jcl_org_map " + whereSql + " and fparentid = " + id); + rs.executeQuery("select id, fname, ftype, fparentid,fobjid,fecid,fnumber from jcl_org_map " + whereSql + " and fparentid = " + id); List> currentList = new ArrayList<>(); while (rs.next()) { Map item = new HashMap<>(); @@ -153,6 +153,8 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { item.put("ftype", rs.getString("ftype")); item.put("parentId", rs.getString("fparentid")); item.put("fnumber", rs.getString("fnumber")); + item.put("fobjid", rs.getString("fobjid")); + item.put("fecid", rs.getString("fecid")); item.put("expand", expand ? "1" : "0"); item.put("hasChildren", hasChildren(rs.getString("id"), true)); currentList.add(item); @@ -203,7 +205,7 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { @Override public Map getUserData(Map request2Map, User user) { Map result = new HashMap<>(); - boolean hasRight = HasRightUtil.hasRight(user, USER_RIGHT, true); + boolean hasRight = HasRightUtil.hasRight(user, USER_RIGHT, true); result.put("hasRight", hasRight); if (!hasRight) { return result; @@ -244,6 +246,7 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { item.put("expand", "1"); item.put("fnumber", rs.getString("fnumber")); item.put("fleader", rs.getString("fleader")); + item.put("fobjid",rs.getString("fobjid")); list.add(item); } @@ -337,7 +340,7 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { private void findUserItemByParantId(String id, int currentLevel, String level, RecordSet rs, List> list, String whereSql, boolean expand) { - rs.executeQuery("select t.id, t.fname, t.ftype, t.fparentid, t.fleadername, t.fleaderimg, t.fleaderjob, t.fplan, t.fonjob, t.fnumber from jcl_org_map t " + whereSql + " and t.fparentid = " + id); + rs.executeQuery("select t.id, t.fname, t.ftype, t.fparentid, t.fleadername, t.fleaderimg, t.fleaderjob, t.fplan, t.fonjob, t.fnumber,t.fobjid,fecid from jcl_org_map t " + whereSql + " and t.fparentid = " + id); List> currentList = new ArrayList<>(); while (rs.next()) { Map item = new HashMap<>(); @@ -352,6 +355,8 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { item.put("fonjob", rs.getString("fonjob")); item.put("fnumber", rs.getString("fnumber")); item.put("expand", expand ? "1" : "0"); + item.put("fobjid", rs.getString("fobjid")); + item.put("fecid", rs.getString("fecid")); item.put("hasChildren", hasChildren(rs.getString("id"), false)); currentList.add(item); }