| @@ -1914,19 +1914,20 @@ public class WxRentContractServiceImpl implements WxRentContractService { | |||||
| //自然月,应该是从本月开始到本月结束 | //自然月,应该是从本月开始到本月结束 | ||||
| if(adjustPeriod.equals(EnumRentContractAdjustPeriod.ADJUST_PERIOD_NAR_MONTH.getCode())){ | if(adjustPeriod.equals(EnumRentContractAdjustPeriod.ADJUST_PERIOD_NAR_MONTH.getCode())){ | ||||
| if(count == 0){ | |||||
| timeVo.setEndDate(EnumContractReceivePeriodUnit.getAfterCalendarNarDay(timeVo.getStartDate(), receivePeriod, dayType)); | |||||
| } | |||||
| timeVo.setEndDate(EnumContractReceivePeriodUnit.getAfterCalendarNarDay(timeVo.getStartDate(), receivePeriod, dayType)); | |||||
| } | } | ||||
| if (count >= 12) { | if (count >= 12) { | ||||
| String a = ""; | String a = ""; | ||||
| } | } | ||||
| //如果是到了每年的截止时间,第一年忽略(是开始时间) | //如果是到了每年的截止时间,第一年忽略(是开始时间) | ||||
| boolean isYearCut = false;//是不是有截断 | |||||
| if (null != yearsEndList && yearsEndList.size() > 0 ) { | if (null != yearsEndList && yearsEndList.size() > 0 ) { | ||||
| Date yearEndDateStart = yearsEndList.get(0); | Date yearEndDateStart = yearsEndList.get(0); | ||||
| //如果开始时间到了年的截止 | |||||
| if (timeVo.getStartDate().equals(yearEndDateStart)) { | if (timeVo.getStartDate().equals(yearEndDateStart)) { | ||||
| yearsEndList.remove(yearEndDateStart); | yearsEndList.remove(yearEndDateStart); | ||||
| //TODO 是不是有1天? | |||||
| }else if (timeVo.getStartDate().after(yearEndDateStart)) { | }else if (timeVo.getStartDate().after(yearEndDateStart)) { | ||||
| //do nothing | //do nothing | ||||
| }else if (timeVo.getStartDate().before(yearEndDateStart)) { | }else if (timeVo.getStartDate().before(yearEndDateStart)) { | ||||
| @@ -1934,6 +1935,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { | |||||
| if (timeVo.getEndDate().after(yearEndDateEnd)) { | if (timeVo.getEndDate().after(yearEndDateEnd)) { | ||||
| timeVo.setEndDate(yearEndDateEnd); | timeVo.setEndDate(yearEndDateEnd); | ||||
| yearsEndList.remove(yearEndDateStart); | yearsEndList.remove(yearEndDateStart); | ||||
| isYearCut = true; | |||||
| }else if(timeVo.getEndDate().equals(yearEndDateEnd)) { | }else if(timeVo.getEndDate().equals(yearEndDateEnd)) { | ||||
| yearsEndList.remove(yearEndDateStart); | yearsEndList.remove(yearEndDateStart); | ||||
| } | } | ||||