|
@@ -785,7 +785,7 @@ public class PayOrderServiceImpl implements PayOrderService {
|
|
|
log.info("【支付异步回调】>>>>>>>>>>>>>>>>>>>>>>>>>>订单商品充值余额(insert[cm_user_balance_record])orderId:" + orderId);
|
|
|
}
|
|
|
|
|
|
- // 线上支付与自主下单送豆
|
|
|
+ // 线上支付与自主下单送豆(已全部收款),最后一笔线上支付成功后,赠送200采美豆
|
|
|
if (3 == order.getReceiptStatus() && 0 == order.getSecondHandOrderFlag()) {
|
|
|
UserBeansHistoryPo beansHistory = new UserBeansHistoryPo();
|
|
|
beansHistory.setUserId(order.getUserId());
|
|
@@ -806,6 +806,7 @@ public class PayOrderServiceImpl implements PayOrderService {
|
|
|
// 自主下单且没有促销活动送豆
|
|
|
Integer orderPromotionsId = payOrderMapper.getOrderPromotionsId(order.getOrderId());
|
|
|
if (1 == order.getOrderType() && null == orderPromotionsId) {
|
|
|
+ // 机构自主下单,根据订单总额的价格区间赠送采美豆数量规则
|
|
|
Double payTotalFee = order.getPayTotalFee();
|
|
|
int num;
|
|
|
if (MathUtil.compare(1000, payTotalFee) > -1) {
|
|
@@ -825,6 +826,12 @@ public class PayOrderServiceImpl implements PayOrderService {
|
|
|
} else {
|
|
|
num = 20000;
|
|
|
}
|
|
|
+ // 超级会员用户标识
|
|
|
+ Integer svipUserId = baseMapper.getSvipUserIdByUserId(order.getUserId());
|
|
|
+ if (null != svipUserId && svipUserId.equals(order.getUserId())){
|
|
|
+ // 超级会员用户采美豆翻倍
|
|
|
+ num = num * 2;
|
|
|
+ }
|
|
|
beansHistory.setBeansType(5);
|
|
|
beansHistory.setNum(num);
|
|
|
if (num > 0) {
|