会员余额支付
This commit is contained in:
parent
6253917cf3
commit
2473a4da25
|
|
@ -190,6 +190,11 @@ public class PayServiceImpl implements PayService {
|
|||
@Override
|
||||
@Transactional(noRollbackFor = PaySuccessException.class)
|
||||
public CzgResult<Object> vipPayOrder(OrderPayParamDTO payParam) {
|
||||
ShopInfo shopInfo = shopInfoService.getById(payParam.getShopId());
|
||||
AssertUtil.isNull(shopInfo, "店铺不存在");
|
||||
if(!shopInfo.getIsAccountPay().equals(1)){
|
||||
return CzgResult.failure("支付失败,店铺暂未开启会员余额支付。");
|
||||
}
|
||||
ShopUser shopUser = new ShopUser();
|
||||
if ("scanCode".equals(payParam.getPayType())) {
|
||||
AssertUtil.isBlank(payParam.getAuthCode(), "会员码不能为空");
|
||||
|
|
@ -197,8 +202,6 @@ public class PayServiceImpl implements PayService {
|
|||
AssertUtil.isNull(o, "会员码已失效");
|
||||
shopUser = shopUserService.getById(o.toString());
|
||||
} else {
|
||||
ShopInfo shopInfo = shopInfoService.getById(payParam.getShopId());
|
||||
AssertUtil.isNull(shopInfo, "店铺不存在");
|
||||
if ("userPay".equals(payParam.getPayType())) {
|
||||
AssertUtil.isNull(payParam.getShopUserId(), "请选择付款人后重试");
|
||||
shopUser = shopUserService.getById(payParam.getShopUserId());
|
||||
|
|
|
|||
Loading…
Reference in New Issue