utils/src/main/java/org/yeshi/utils/DateUtil.java
@@ -54,7 +54,17 @@ return datatime; } /** * 通过时间秒毫秒数判断两个时间的间隔 * @param date1 * @param date2 * @return */ public static int differentDaysByMillisecond(Date start, Date end) { return (int) ((end.getTime() - start.getTime()) / (1000*3600*24)); } public String transferLongToDate(String dateFormat, Long millSec) { SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date date = new Date(millSec); @@ -94,7 +104,7 @@ return false; } } /** * 指定日期加上天数后的日期 * @@ -162,8 +172,8 @@ break; // 时间结束 } } return listDate; } }