@@ -39,6 +39,6 @@ public class PlatformCalendarRequest {
if(StringUtils.isNotBlank(requestDateStr)) {
return requestDateStr + "-01";
}
- return requestDateStr;
+ return requestDateDayStr;
@@ -106,7 +106,7 @@ public class PlatformCalendarService {
platformCalendarRequest);
//获取请求日期的天数
int monthDayNum = CommonUtil.getLastDayNumOfMonthFromDateStr(
- platformCalendarRequest.getRequestDateDayStr(), CommonConstants.PlatformCalendarConstants.REQUEST_DATE_FORMAT);
+ platformCalendarRequest.getRequestDateStr(), CommonConstants.PlatformCalendarConstants.REQUEST_DATE_FORMAT);
//循环设置每日的数据
for (int day = 1; day <= monthDayNum; day++) {
addCalendarLift(dayToCalendarLift, dayToMtRecord, dayToMtPlan, dayToEmergencyRecord, dayToAnnualInspection, day);
@@ -120,11 +120,7 @@ public class CommonUtil {
if (transDate != null) {
int dayNum = getLastDayNumOfMonth(transDate);
for (int monthDay = 1; monthDay <= dayNum; monthDay++) {
- Map<Integer, Long> liftStatusToNum = new HashMap<>();
- for (int liftStatus : CommonConstants.PlatformCalendarConstants.LIFT_STATUS_ARRAY) {
- liftStatusToNum.put(liftStatus, 0L);
- }
- dayToLiftStatusToNum.put(monthDay, liftStatusToNum);
+ dayToLiftStatusToNum.put(monthDay, new HashMap<>());
return dayToLiftStatusToNum;