|
|
|
@@ -595,7 +595,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
final IdWorker idWorker = IdWorker.get();
|
|
|
|
List<Long> shopIds = record.shopIdsByRentInfo();
|
|
|
|
//根据关联的店铺面积来分金额
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = record.getRentShopAreaRate();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = record.getRentShopArea();
|
|
|
|
if (null == shopAreaRateMap) {
|
|
|
|
throw new MallinkException(ErrorCode.SYS_SERVER_ERROR.getCode(),"无店铺信息");
|
|
|
|
}
|
|
|
|
@@ -640,7 +640,9 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
for (int i = 0 ; i < shopIds.size(); i ++) {
|
|
|
|
WxAllBill b = new WxAllBill();
|
|
|
|
Long sid = shopIds.get(i);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(record.getRentArea()),record.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
|
|
|
|
try {
|
|
|
|
BeanUtils.copyProperties(b, bill);
|
|
|
|
b.setId(idWorker.nextId());
|
|
|
|
@@ -686,7 +688,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
int count = 1;
|
|
|
|
List<Long> shopIds = record.shopIdsByRentInfo();
|
|
|
|
//根据关联的店铺面积来分金额
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = record.getRentShopAreaRate();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = record.getRentShopArea();
|
|
|
|
if (null == shopAreaRateMap) {
|
|
|
|
throw new MallinkException(ErrorCode.SYS_SERVER_ERROR.getCode(),"无店铺信息");
|
|
|
|
}
|
|
|
|
@@ -710,7 +712,9 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
}
|
|
|
|
for (int i = 0 ; i < shopIds.size(); i ++) {
|
|
|
|
Long sid = shopIds.get(i);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(record.getRentArea()),record.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
|
|
|
|
WxAllBill bill = new WxAllBill();
|
|
|
|
bill.setId(idWorker.nextId());
|
|
|
|
Date date = new Date();
|
|
|
|
@@ -903,7 +907,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
|
|
|
|
//根据不同的科目生成不同的押金账单
|
|
|
|
Map<Long,WxEnergyFees> feesMap = wxRentContract.getDepositEnergyFees(typeMap);
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = wxRentContract.getRentShopAreaRate();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = wxRentContract.getRentShopArea();
|
|
|
|
if (null == shopAreaRateMap) {
|
|
|
|
throw new MallinkException(ErrorCode.SYS_SERVER_ERROR.getCode(),"无店铺信息");
|
|
|
|
}
|
|
|
|
@@ -917,7 +921,9 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
|
|
|
|
for (int i = 0 ; i < shopIdList.size(); i++ ) {
|
|
|
|
Long sid = shopIdList.get(i);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(wxRentContract.getRentArea()),wxRentContract.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
|
|
|
|
WxAllBill wxBillDeposit = new WxAllBill();
|
|
|
|
wxBillDeposit.setId(idWorker.nextId());
|
|
|
|
wxBillDeposit.setRentContractId(wxRentContract.getId());
|
|
|
|
@@ -1238,7 +1244,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
}
|
|
|
|
|
|
|
|
List<Long> shopIdList = wxRentContract.shopIdsByRentInfo();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = wxRentContract.getRentShopAreaRate();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = wxRentContract.getRentShopArea();
|
|
|
|
if (null == shopAreaRateMap) {
|
|
|
|
throw new MallinkException(ErrorCode.SYS_SERVER_ERROR.getCode(),"无店铺信息");
|
|
|
|
}
|
|
|
|
@@ -1453,7 +1459,8 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
for (int g = 0 ; g < shopIdList.size(); g ++ ){
|
|
|
|
WxAllBill rs = new WxAllBill();
|
|
|
|
Long sid = shopIdList.get(g);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(wxRentContract.getRentArea()),wxRentContract.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
try {
|
|
|
|
BeanUtils.copyProperties(rs, rb);
|
|
|
|
rs.setId(idWorker.nextId());
|
|
|
|
@@ -1485,7 +1492,8 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
for (int g = 0 ; g < shopIdList.size(); g ++ ){
|
|
|
|
WxAllBill rs = new WxAllBill();
|
|
|
|
Long sid = shopIdList.get(g);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(wxRentContract.getRentArea()),wxRentContract.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
try {
|
|
|
|
BeanUtils.copyProperties(rs, rb);
|
|
|
|
rs.setId(idWorker.nextId());
|
|
|
|
@@ -2756,7 +2764,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
}
|
|
|
|
|
|
|
|
List<Long> shopIdList = rentcontract.shopIdsByRentInfo();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = rentcontract.getRentShopAreaRate();
|
|
|
|
Map<Long, BigDecimal> shopAreaRateMap = rentcontract.getRentShopArea();
|
|
|
|
WxShopUsers suq = new WxShopUsers();
|
|
|
|
suq.updateTenantInfo(rentcontract);
|
|
|
|
suq.setShopIds(shopIdList);
|
|
|
|
@@ -2813,7 +2821,9 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
List<WxAllBill> billList = new ArrayList<WxAllBill>();
|
|
|
|
for (int i = 0 ; i < shopIds.size(); i++) {
|
|
|
|
Long sid = shopIds.get(i);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(rentcontract.getRentArea()),rentcontract.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
|
|
|
|
String newmoney = new BigDecimal(bussinessmoney).multiply(shoprate).setScale(rentcontract.getDecimalSize()).toPlainString();
|
|
|
|
WxAllBill b = new WxAllBill();
|
|
|
|
final IdWorker idWorker = IdWorker.get();
|
|
|
|
@@ -2862,7 +2872,8 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
List<WxAllBill> billList = new ArrayList<WxAllBill>();
|
|
|
|
for (int i = 0 ; i < shopIds.size() ; i ++) {
|
|
|
|
Long sid = shopIds.get(i);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(rentcontract.getRentArea()),rentcontract.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
|
|
|
|
WxAllBill bmbill = new WxAllBill();
|
|
|
|
final IdWorker idWorker = IdWorker.get();
|
|
|
|
@@ -2902,7 +2913,8 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
List<WxAllBill> billList = new ArrayList<WxAllBill>();
|
|
|
|
for (int i = 0 ; i < shopIds.size(); i++) {
|
|
|
|
Long sid = shopIds.get(i);
|
|
|
|
BigDecimal shoprate = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprentArea = shopAreaRateMap.get(sid);
|
|
|
|
BigDecimal shoprate = shoprentArea.divide(new BigDecimal(rentcontract.getRentArea()),rentcontract.getDecimalSize(),BigDecimal.ROUND_HALF_UP);
|
|
|
|
WxAllBill bmbill = new WxAllBill();
|
|
|
|
final IdWorker idWorker = IdWorker.get();
|
|
|
|
bmbill.setId(idWorker.nextId());
|
|
|
|
|