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)) {