fix: allow h5 place order for configured countries

This commit is contained in:
zhx 2026-06-24 14:28:15 +08:00
parent 5a6cebc0ba
commit 52658d5d65

View File

@ -109,8 +109,8 @@ public class PayWebH5PlaceOrderCmdExe {
PayCountry payCountry = payCountryService.getById(cmd.getPayCountryId()); PayCountry payCountry = payCountryService.getById(cmd.getPayCountryId());
ResponseAssert.notNull(CommonErrorCode.NOT_FOUND_RECORD_INFO, payCountry); ResponseAssert.notNull(CommonErrorCode.NOT_FOUND_RECORD_INFO, payCountry);
ResponseAssert.isTrue(ResponseErrorCode.REQUEST_PARAMETER_ERROR, // H5 的支付国家和支付方式开放性由 app 本地 JSON 控制后端只确认国家记录存在并用它计算汇率
Boolean.TRUE.equals(payCountry.getShelf())); // 避免后台开通支付国家开关和 H5 JSON 配置不一致时options 能展示但下单被误拦截
ResponseAssert.isTrue(ResponseErrorCode.REQUEST_PARAMETER_ERROR, ResponseAssert.isTrue(ResponseErrorCode.REQUEST_PARAMETER_ERROR,
Objects.isNull(commodity.getPayCountryId()) Objects.isNull(commodity.getPayCountryId())
|| Objects.equals(commodity.getPayCountryId(), payCountry.getId())); || Objects.equals(commodity.getPayCountryId(), payCountry.getId()));