|
|
|
@@ -2635,9 +2635,11 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
List<Date> yearList = this.getYearList(rentPriceArrs.length, 12, rentcontract.getRentalStartDate(),null);
|
|
|
|
int yearIndex = 0;
|
|
|
|
for( int i = 0 ; i < yearList.size() ; i ++) {
|
|
|
|
Date yearEndDate = yearList.get(i);
|
|
|
|
if (rentBill.getEndtime().before(yearEndDate) || rentBill.getEndtime().equals(yearEndDate)) {
|
|
|
|
yearIndex = i-1;
|
|
|
|
Date yearStartDate = yearList.get(i);
|
|
|
|
Date yearEndDate = DateUtils.getTimeAfterMonths(12, yearStartDate);
|
|
|
|
if (rentBill.getStarttime().equals(yearStartDate) ||
|
|
|
|
(rentBill.getStarttime().after(yearStartDate) && (rentBill.getEndtime().before(yearEndDate) || rentBill.getEndtime().equals(yearEndDate)) )) {
|
|
|
|
yearIndex = i;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
@@ -2653,6 +2655,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
if (null != operationManagerPriceArrs) {
|
|
|
|
rentTotal = rentTotal.add(new BigDecimal(operationManagerPriceArrs[yearIndex]));
|
|
|
|
}
|
|
|
|
//此处需要物业合同合租金合同的计费周期一致,严谨的需要用到上面计算的propertyPrice
|
|
|
|
if (null != propertyContractArrs) {
|
|
|
|
rentTotal = rentTotal.add(new BigDecimal(propertyContractArrs[yearIndex]));
|
|
|
|
}
|
|
|
|
@@ -3084,7 +3087,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
yearIndex = 0;
|
|
|
|
}
|
|
|
|
StringBuffer sb = new StringBuffer("");
|
|
|
|
return handleBills(sb,rentcontract,null,owe,null,rentcontract.getYearsEnd(),rentcontract.getYearsEnd(),EnumBillExtraCreateFrom.RNET_TIAODIAN_HUISUAN,null,rentPriceArrs,bussinessManagerPriceArrs,operationManagerPriceArrs,propertyContractArrs,yearIndex);
|
|
|
|
return handleBills(sb,rentcontract,null,owe,null,rentcontract.getYearsBegin(),rentcontract.getYearsEnd(),EnumBillExtraCreateFrom.RNET_TIAODIAN_HUISUAN,null,rentPriceArrs,bussinessManagerPriceArrs,operationManagerPriceArrs,propertyContractArrs,yearIndex);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|