|
|
|
@@ -593,7 +593,17 @@ public class WxRentContractController extends WxContractBaseController { |
|
|
|
|
|
|
|
private void validShop(WxRentContract rentContract) throws Exception { |
|
|
|
//判断该合同的店铺是不是在商户的店铺的绑定关系里面 |
|
|
|
List<Long> shopIds = wxMerchantService.getMerchantShopIds(rentContract.getMerchantId()); |
|
|
|
List<Long> shopIds = null; |
|
|
|
WxMerchant merchant = wxMerchantService.selectById(rentContract.getMerchantId()); |
|
|
|
if (merchant.getIsPrivate() == EnumYesOrNo.YES.getCode()) { |
|
|
|
WxShop shq = new WxShop(); |
|
|
|
shq.updateTenantInfo(merchant); |
|
|
|
shq.setQueryShopNumber(merchant.getCreateShopNumber()); |
|
|
|
shq.setIsDel(EnumYesOrNo.NO.getCode()); |
|
|
|
shopIds = wxShopService.getShopIds(shq); |
|
|
|
}else { |
|
|
|
shopIds = wxMerchantService.getMerchantShopIds(rentContract.getMerchantId()); |
|
|
|
} |
|
|
|
if (null == shopIds) { |
|
|
|
throw new MallinkException(Result.ERROR, "该商户未绑定任何商铺。"); |
|
|
|
} |
|
|
|
|