From 7df8602e97e4db6d79eb84254c3175b2278fdcec Mon Sep 17 00:00:00 2001 From: MustangDen <670124965@qq.com> Date: Fri, 8 Jul 2022 16:24:30 +0800 Subject: [PATCH] =?UTF-8?q?fix=20=E7=BB=84=E7=BB=87=E6=9E=B6=E6=9E=84sql?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../engine/organization/service/impl/OrgChartServiceImpl.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/com/engine/organization/service/impl/OrgChartServiceImpl.java b/src/com/engine/organization/service/impl/OrgChartServiceImpl.java index 2403be70..06a8a7f1 100644 --- a/src/com/engine/organization/service/impl/OrgChartServiceImpl.java +++ b/src/com/engine/organization/service/impl/OrgChartServiceImpl.java @@ -74,7 +74,7 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { } String whereSql = " where 1 = 1 "; - whereSql += " and (fdatebegin <= '"+ date +"' and fdateend >= '"+ date +"') or (fdatebegin <= '"+ date +"' and fdateend is null ) "; + whereSql += " and ((fdatebegin <= '"+ date +"' and fdateend >= '"+ date +"') or (fdatebegin <= '"+ date +"' and fdateend is null )) "; whereSql += " and fclass = " + fclass +" "; if("0".equals(fisvitual)) { @@ -158,7 +158,7 @@ public class OrgChartServiceImpl extends Service implements OrgChartService { } String whereSql = " where 1 = 1 "; - whereSql += " and (t.fdatebegin <= '"+ date +"' and t.fdateend >= '"+ date +"') or (t.fdatebegin <= '"+ date +"' and t.fdateend is null ) "; + whereSql += " and ((t.fdatebegin <= '"+ date +"' and t.fdateend >= '"+ date +"') or (t.fdatebegin <= '"+ date +"' and t.fdateend is null )) "; whereSql += " and t.fclass = " + fclass +" "; if("0".equals(fisvitual)) {