|
|
@ -76,12 +76,12 @@ public class ObjectUtils { |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public static Map LocalDateConvertMap(LocalDateTime dateTime,String prefix,String split) { |
|
|
|
public static Map LocalDateConvertMap(LocalDateTime dateTime,String prefix,String split) { |
|
|
|
HashMap<String, Object> result = new HashMap<String, Object>() {{ |
|
|
|
HashMap<String, Object> result = new HashMap<String, Object>() {{ |
|
|
|
put(prefix + split + "year", dateTime.getYear()); |
|
|
|
put(prefix + split + "year",String.format("%02d", dateTime.getYear())); |
|
|
|
put(prefix + split + "month", dateTime.getMonthValue()); |
|
|
|
put(prefix + split + "month",String.format("%02d",dateTime.getMonthValue())); |
|
|
|
put(prefix + split + "day", dateTime.getDayOfMonth()); |
|
|
|
put(prefix + split + "day",String.format("%02d", dateTime.getDayOfMonth())); |
|
|
|
put(prefix + split + "hour", dateTime.getHour()); |
|
|
|
put(prefix + split + "hour",String.format("%02d", dateTime.getHour())); |
|
|
|
put(prefix + split + "minuter", dateTime.getMinute()); |
|
|
|
put(prefix + split + "minuter", String.format("%02d",dateTime.getMinute())); |
|
|
|
put(prefix + split + "second", dateTime.getSecond()); |
|
|
|
put(prefix + split + "second",String.format("%02d",dateTime.getSecond())); |
|
|
|
}}; |
|
|
|
}}; |
|
|
|
return result; |
|
|
|
return result; |
|
|
|
} |
|
|
|
} |
|
|
|