update
This commit is contained in:
@@ -701,6 +701,14 @@ public class DateUtils extends PropertyEditorSupport {
|
||||
return null;
|
||||
}
|
||||
|
||||
public static Date parseDatetimeShort(String str) {
|
||||
try {
|
||||
return time_sdf.get().parse(str);
|
||||
} catch (Exception e) {
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断两个时间是否是同一天
|
||||
*
|
||||
|
||||
@@ -87,7 +87,7 @@ public class ExperimentRadiationProcessServiceImpl extends ServiceImpl<Experimen
|
||||
detailMap.forEach((key, value) -> value.forEach(v1 -> {
|
||||
String startTime = v1.get("startTime");
|
||||
String endTime = v1.get("endTime");
|
||||
list.add(new TimeRange(DateUtils.parseDatetime(startTime), DateUtils.parseDatetime(endTime)));
|
||||
list.add(new TimeRange(DateUtils.parseDatetimeShort(startTime), DateUtils.parseDatetimeShort(endTime)));
|
||||
}));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user