|
|
@@ -735,15 +735,20 @@ public class WxPropertyContractServiceImpl implements WxPropertyContractService |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@Override |
|
|
@Override |
|
|
public List<WxBillProperty> buildBill(WxRentContract wxRentContract) { |
|
|
|
|
|
|
|
|
public List<WxBillProperty> buildBill(WxPropertyContract wxPropertyContract) { |
|
|
//生成预览账单 |
|
|
//生成预览账单 |
|
|
//根据租赁合同找到对应的物业合同,生成物业账单 |
|
|
//根据租赁合同找到对应的物业合同,生成物业账单 |
|
|
WxPropertyContract propertyContract = wxPropertyContractMapper.findOneByRentId(wxRentContract); |
|
|
|
|
|
|
|
|
WxPropertyContract propertyContract = wxPropertyContractMapper.selectByPrimaryKey(wxPropertyContract.getId()); |
|
|
if(propertyContract != null) { |
|
|
if(propertyContract != null) { |
|
|
if(!wxRentContract.getLease().equals(propertyContract.getLease()) |
|
|
|
|
|
||!wxRentContract.getPrice().equals(propertyContract.getPrice())){ |
|
|
|
|
|
|
|
|
if(!wxPropertyContract.getReceivePeriod().equals(propertyContract.getReceivePeriod()) |
|
|
|
|
|
||!wxPropertyContract.getPrice().equals(propertyContract.getPrice()) |
|
|
|
|
|
||!wxPropertyContract.getDeposit().equals(propertyContract.getDeposit())){ |
|
|
wxBillPropertyMapper.deletePreviewBill(propertyContract); |
|
|
wxBillPropertyMapper.deletePreviewBill(propertyContract); |
|
|
//重新生成 |
|
|
//重新生成 |
|
|
|
|
|
propertyContract.setPrice(wxPropertyContract.getPrice()); |
|
|
|
|
|
propertyContract.setDeposit(wxPropertyContract.getDeposit()); |
|
|
|
|
|
propertyContract.setReceivePeriod(wxPropertyContract.getReceivePeriod()); |
|
|
|
|
|
propertyContract.setPayAccount(wxPropertyContract.getPayAccount()); |
|
|
List<WxBillProperty> billList = buildProperty(new WxMerchant(),propertyContract,EnumIsPreview.YES.getCode()); |
|
|
List<WxBillProperty> billList = buildProperty(new WxMerchant(),propertyContract,EnumIsPreview.YES.getCode()); |
|
|
return billList; |
|
|
return billList; |
|
|
} |
|
|
} |
|
|
|