|
|
|
@@ -1213,6 +1213,23 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
priceArrs[i] = priceD.setScale(0, RoundingMode.HALF_EVEN).longValue(); |
|
|
|
} |
|
|
|
} |
|
|
|
}else if (wxRentContract.getType().equals(EnumRentContractType.RENT_BY_CUSTOMIZE.getCode())) { |
|
|
|
String adjustRatio = wxRentContract.getAdjustRatio(); |
|
|
|
JSONArray array = JSONArray.parseArray(adjustRatio); |
|
|
|
if(array != null && array.size() > 0){ |
|
|
|
priceArrs = new long[array.size()]; |
|
|
|
size = array.size(); |
|
|
|
for (int i=0;i<array.size();i++){ |
|
|
|
JSONObject jsonObject = array.getJSONObject(i); |
|
|
|
String perMonthMoney = jsonObject.getString("perMonthMoney"); |
|
|
|
if(StringUtils.isNotBlank(perMonthMoney) && !"0".equals(perMonthMoney)){ |
|
|
|
BigDecimal priceD = new BigDecimal(perMonthMoney).multiply(new BigDecimal(12)).divide(new BigDecimal(100)); |
|
|
|
priceArrs[i] = priceD.setScale(0, RoundingMode.HALF_EVEN).longValue(); |
|
|
|
}else{ |
|
|
|
priceArrs[i] = 0; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}else{ |
|
|
|
return new ArrayList<>(); |
|
|
|
} |
|
|
|
|