| @@ -196,4 +196,12 @@ public class WxRentContractController extends BaseController { | |||||
| return new ResultData(); | return new ResultData(); | ||||
| } | } | ||||
| @GetMapping("/getMerchants") | |||||
| @SystemControllerLog(description = "租赁合同-获取已签约租赁合同且未有物业的商户") | |||||
| public ResultData getMerchants(@ModelAttribute WxRentContract wxRentContract) { | |||||
| logger.debug("[" + getIpAddr() + "] WxRentContractController::getMerchants"); | |||||
| wxRentContract.setTenantId(getTenantId()); | |||||
| return new ResultData(Result.SUCCESS, "查询成功", wxRentContractService.getMerchants(wxRentContract)); | |||||
| } | |||||
| } | } | ||||
| @@ -44,4 +44,7 @@ public interface WxRentContractMapper extends CommonMapper<WxRentContract, Strin | |||||
| void updateStatus(WxRentContract wxRentContract); | void updateStatus(WxRentContract wxRentContract); | ||||
| long queryOweCount(WxRentContract wxRentContract); | long queryOweCount(WxRentContract wxRentContract); | ||||
| List<WxRentContract> getMerchants(WxRentContract wxRentContract); | |||||
| } | } | ||||
| @@ -75,4 +75,5 @@ public interface WxRentContractService { | |||||
| void buildDeposit(WxMerchant wxMerchant, Long userId,Long rentContractId); | void buildDeposit(WxMerchant wxMerchant, Long userId,Long rentContractId); | ||||
| Object getMerchants(WxRentContract wxRentContract); | |||||
| } | } | ||||
| @@ -451,6 +451,12 @@ public class WxRentContractServiceImpl implements WxRentContractService { | |||||
| } | } | ||||
| } | } | ||||
| @Override | |||||
| public Object getMerchants(WxRentContract wxRentContract) { | |||||
| List<WxRentContract> rentContractList = wxRentContractMapper.getMerchants(wxRentContract); | |||||
| return rentContractList; | |||||
| } | |||||
| @Override | @Override | ||||
| @Transactional(rollbackFor = {Exception.class}) | @Transactional(rollbackFor = {Exception.class}) | ||||
| public List<WxBillRent> buildRent(WxMerchant wxMerchant, Long userId,WxRentContract rentContract,Integer isPreview) { | public List<WxBillRent> buildRent(WxMerchant wxMerchant, Long userId,WxRentContract rentContract,Integer isPreview) { | ||||
| @@ -212,5 +212,12 @@ | |||||
| select count(*) from wx_rent_contract r,wx_bill_rent b | select count(*) from wx_rent_contract r,wx_bill_rent b | ||||
| where b.rent_contract_id = r.id and b.status = 1 and r.id = #{id} | where b.rent_contract_id = r.id and b.status = 1 and r.id = #{id} | ||||
| </select> | </select> | ||||
| <select id="getMerchants" parameterType="com.iformall.domain.po.WxRentContract" | |||||
| resultType="com.iformall.domain.po.WxRentContract"> | |||||
| select * from wx_rent_contract where status in(2,3,4) | |||||
| and merchant_id not in(select merchant_id from wx_property_contract where status in(2,3,4)) | |||||
| <if test=" null != rentShopType ">and rent_shop_type = #{rentShopType}</if> | |||||
| </select> | |||||
| </mapper> | </mapper> | ||||