充值赠送积分
This commit is contained in:
parent
953099c104
commit
55c71422fd
|
|
@ -1,7 +1,6 @@
|
|||
package com.czg.service.account.service.impl;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.date.LocalDateTimeUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
|
|
@ -13,10 +12,7 @@ import com.czg.account.entity.ShopActivate;
|
|||
import com.czg.account.entity.ShopActivateCouponRecord;
|
||||
import com.czg.account.entity.ShopCoupon;
|
||||
import com.czg.account.entity.ShopUser;
|
||||
import com.czg.account.service.ShopActivateCouponRecordService;
|
||||
import com.czg.account.service.ShopActivateService;
|
||||
import com.czg.account.service.ShopCouponService;
|
||||
import com.czg.account.service.ShopUserService;
|
||||
import com.czg.account.service.*;
|
||||
import com.czg.enums.ShopUserFlowBizEnum;
|
||||
import com.czg.sa.StpKit;
|
||||
import com.czg.service.account.mapper.ShopActivateMapper;
|
||||
|
|
@ -50,6 +46,8 @@ public class ShopActivateServiceImpl extends ServiceImpl<ShopActivateMapper, Sho
|
|||
private ShopActivateCouponRecordService inRecordService;
|
||||
@Resource
|
||||
private ShopUserService shopUserService;
|
||||
@Resource
|
||||
private MemberPointsService pointsService;
|
||||
|
||||
@Override
|
||||
public List<ShopActivateDTO> getList(Long shopId) {
|
||||
|
|
@ -156,6 +154,9 @@ public class ShopActivateServiceImpl extends ServiceImpl<ShopActivateMapper, Sho
|
|||
//更新会员余额 并生成流水
|
||||
shopUserService.updateMoney(shopUser.getShopId(), shopUserMoneyEditDTO);
|
||||
}
|
||||
if (activate.getGiftPoints() != null && activate.getGiftPoints() > 0) {
|
||||
pointsService.addPoints(shopUser.getId(), activate.getGiftPoints(), "储值赠送积分", null);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -347,7 +347,8 @@ public class PayServiceImpl implements PayService {
|
|||
AssertUtil.isNull(shopInfo, "店铺不存在");
|
||||
if (shopInfo.getIsMemberInPwd().equals(1)) {
|
||||
AssertUtil.isBlank(shopInfo.getOperationPwd(), "请设置操作密码后使用");
|
||||
if (!shopInfo.getOperationPwd().equals(MD5Util.md5AsHex(payParam.getPwd()))) {
|
||||
AssertUtil.isBlank(payParam.getPwd(), "请输入操作密码后充值");
|
||||
if (!shopInfo.getOperationPwd().equals(SecureUtil.md5(payParam.getPwd()))) {
|
||||
return CzgResult.failure("支付密码错误");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue