Browse Source

Merge branch 'wrdp' into 'develop'

Wrdp

See merge request o2oa/o2oa!2752
o2null 5 years ago
parent
commit
1f73755050

+ 2 - 2
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/jaxrs/export/ActionExportAll.java

@@ -4,6 +4,7 @@ import java.io.ByteArrayOutputStream;
 import java.util.ArrayList;
 import java.util.Date;
 import java.util.List;
+import java.util.Objects;
 
 import javax.persistence.EntityManager;
 import javax.persistence.criteria.CriteriaBuilder;
@@ -285,9 +286,8 @@ public class ActionExportAll extends BaseAction {
 				row.createCell(2).setCellValue(person.getMobile());
 				row.createCell(3).setCellValue(person.getEmployee());
 				row.createCell(4).setCellValue(person.getOfficePhone());
-				row.createCell(5).setCellValue(person.getGenderType().toString());
+				row.createCell(5).setCellValue(Objects.toString(person.getGenderType(),""));
 				row.createCell(6).setCellValue(person.getMail());
-				
 			}
 		}
 	}

+ 5 - 4
o2server/x_query_core_express/src/main/java/com/x/query/core/express/plan/DateRangeEntry.java

@@ -58,7 +58,8 @@ public class DateRangeEntry extends GsonPropertyObject {
 			if (StringUtils.isEmpty(year)) {
 				year = DateTools.format(now, DateTools.format_yyyy);
 			}
-			if (null == season) {
+			/*0表示当前季度*/
+			if (null == season || season == 0) {
 				season = DateTools.season(now);
 			}
 			this.start = DateTools.floorSeason(year, season, adjust);
@@ -102,13 +103,13 @@ public class DateRangeEntry extends GsonPropertyObject {
 			//2019-07-17 O2LEE 优化:不能全部为空。但如果有一个为空,可能前推或者后延一年。
 			if (null == this.start  && null == this.completed) {
 				throw new Exception("begin and end can not be all null when dateRangeEntry on type appoint.");
-			}			
+			}
 			//2019-07-17 O2LEE 优化:如果开始时间不为空,结束时间为空,那么按开始时间后推一年为结束时间
 			if( null != this.start ) {
 				if( null == this.completed ) {
 					this.completed = DateTools.getDateAfterYearAdjust( this.start , 1, 0, 0);
 				}
-			}			
+			}
 			//2019-07-17 O2LEE 优化:如果结束时间不为空,开始时间为空,那么按结束时间前推一年为开始时间
 			if( null != this.completed ) {
 				if( null == this.start ) {
@@ -127,4 +128,4 @@ public class DateRangeEntry extends GsonPropertyObject {
 		}
 	}
 
-}
+}

+ 3 - 3
o2server/x_query_core_express/src/main/java/com/x/query/core/express/plan/ProcessPlatformPlan.java

@@ -480,13 +480,13 @@ public class ProcessPlatformPlan extends Plan {
 				return null;
 			}
 			if (null == this.dateRange.start) {
-				return cb.lessThanOrEqualTo(root.get(WorkCompleted_.completedTime), this.dateRange.completed);
+				return cb.lessThanOrEqualTo(root.get(WorkCompleted_.startTime), this.dateRange.completed);
 			} else if (null == this.dateRange.completed) {
 				return cb.greaterThanOrEqualTo(root.get(WorkCompleted_.startTime), this.dateRange.start);
 			} else {
 				return cb.and(cb.greaterThanOrEqualTo(root.get(WorkCompleted_.startTime), this.dateRange.start),
-						cb.lessThanOrEqualTo(root.get(WorkCompleted_.completedTime), this.dateRange.completed));
+						cb.lessThanOrEqualTo(root.get(WorkCompleted_.startTime), this.dateRange.completed));
 			}
 		}
 	}
-}
+}