|
|
|
@@ -103,7 +103,7 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
WxFlowRecordMapper wxFlowRecordMapper; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
WxPropertyContractService wxPropertyContractService; |
|
|
|
WxBillPropertyMapper wxBillPropertyMapper; |
|
|
|
|
|
|
|
@Override |
|
|
|
public Map<String, Object> listAsPage(WxRentContract record, Integer pageIndex, Integer pageSize) { |
|
|
|
@@ -2017,6 +2017,27 @@ public class WxRentContractServiceImpl implements WxRentContractService { |
|
|
|
} |
|
|
|
return list; |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public void endContract(WxRentContract wxRentContract) { |
|
|
|
//终止租赁合同,同时终止物业合同 |
|
|
|
if(EnumEndProperty.END_RENT_AND_PROPERTY.getCode().equals(wxRentContract.getEndProperty())){ |
|
|
|
WxPropertyContract wxPropertyContract = new WxPropertyContract(); |
|
|
|
wxPropertyContract.setRentContractId(wxRentContract.getId()); |
|
|
|
wxPropertyContract.setStatus(EnumRentContractStatus.CONTRACT_TERMINATE.getCode()); |
|
|
|
wxPropertyContractMapper.updateStatusByRentContractId(wxPropertyContract); |
|
|
|
|
|
|
|
//物业账单失效 |
|
|
|
wxBillPropertyMapper.updateInvalidStatusByRent(wxRentContract); |
|
|
|
} |
|
|
|
//租赁账单失效 |
|
|
|
WxBillRent wxBillRent = new WxBillRent(); |
|
|
|
wxBillRent.setRentContractId(wxRentContract.getId()); |
|
|
|
wxBillRentMapper.updateInvalidStatus(wxBillRent); |
|
|
|
|
|
|
|
//解绑商户和商铺关系 |
|
|
|
wxMerchantService.disable(wxRentContractMapper.selectByPrimaryKey(wxRentContract.getId()).getMerchantId()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|