Просмотр исходного кода

Merge branch 'release_toaliyun_real_20230323' of https://git.malls.iformall.com/server/formallProject into release_toaliyun_real_20230323

release_toaliyun_real
xhxu 3 лет назад
Родитель
Сommit
4f1fee7a9e
7 измененных файлов: 147 добавлений и 2 удалений
  1. +103
    -0
      mallinkAdmin/src/main/resources/db/migration/V20230323000001_press.sql
  2. +13
    -0
      mallinkCApi/src/main/java/com/iformall/controller/WxPressOrderController.java
  3. +3
    -0
      mallinkService/src/main/java/com/iformall/domain/po/WxCoupon.java
  4. +4
    -0
      mallinkService/src/main/java/com/iformall/service/WxOrderPressService.java
  5. +1
    -0
      mallinkService/src/main/java/com/iformall/service/WxOrderService.java
  6. +9
    -0
      mallinkService/src/main/java/com/iformall/service/impl/WxOrderPressServiceImpl.java
  7. +14
    -2
      mallinkService/src/main/resources/mapper/WxCouponMapper.xml

+ 103
- 0
mallinkAdmin/src/main/resources/db/migration/V20230323000001_press.sql Просмотреть файл

@@ -99,3 +99,106 @@ alter table wx_coupon_97 add column press_pay_reduce_stock int(1) not null defa
alter table wx_coupon_98 add column press_pay_reduce_stock int(1) not null default 0 comment '砍价支付扣库存EnumYesOrNo' after press_limit_hours; alter table wx_coupon_98 add column press_pay_reduce_stock int(1) not null default 0 comment '砍价支付扣库存EnumYesOrNo' after press_limit_hours;
alter table wx_coupon_99 add column press_pay_reduce_stock int(1) not null default 0 comment '砍价支付扣库存EnumYesOrNo' after press_limit_hours; alter table wx_coupon_99 add column press_pay_reduce_stock int(1) not null default 0 comment '砍价支付扣库存EnumYesOrNo' after press_limit_hours;



alter table wx_coupon_0 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_1 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_2 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_3 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_4 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_5 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_6 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_7 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_8 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_9 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_10 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_11 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_12 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_13 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_14 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_15 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_16 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_17 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_18 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_19 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_20 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_21 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_22 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_23 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_24 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_25 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_26 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_27 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_28 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_29 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_30 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_31 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_32 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_33 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_34 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_35 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_36 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_37 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_38 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_39 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_40 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_41 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_42 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_43 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_44 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_45 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_46 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_47 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_48 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_49 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_50 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_51 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_52 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_53 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_54 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_55 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_56 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_57 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_58 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_59 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_60 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_61 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_62 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_63 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_64 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_65 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_66 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_67 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_68 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_69 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_70 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_71 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_72 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_73 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_74 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_75 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_76 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_77 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_78 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_79 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_80 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_81 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_82 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_83 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_84 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_85 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_86 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_87 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_88 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_89 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_90 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_91 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_92 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_93 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_94 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_95 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_96 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_97 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_98 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;
alter table wx_coupon_99 add column press_support_is_new int(1) not null default 0 comment '砍价帮砍人是否为新用户EnumYesOrNo' after press_pay_reduce_stock;



+ 13
- 0
mallinkCApi/src/main/java/com/iformall/controller/WxPressOrderController.java Просмотреть файл

@@ -10,6 +10,7 @@ import com.iformall.domain.po.base.TenantEntity;
import com.iformall.domain.vo.WxCouponCVo; import com.iformall.domain.vo.WxCouponCVo;
import com.iformall.enums.EnumOrderPressStatus; import com.iformall.enums.EnumOrderPressStatus;
import com.iformall.enums.EnumOrderStatus; import com.iformall.enums.EnumOrderStatus;
import com.iformall.enums.EnumYesOrNo;
import com.iformall.exception.MallinkException; import com.iformall.exception.MallinkException;
import com.iformall.service.WxCouponService; import com.iformall.service.WxCouponService;
import com.iformall.service.WxOrderPressService; import com.iformall.service.WxOrderPressService;
@@ -176,6 +177,18 @@ public class WxPressOrderController extends BaseController {
logger.error("用户已参与砍价"); logger.error("用户已参与砍价");
return new ResultData(ErrorCode.COUPON_PRESS_IS_EXIST); return new ResultData(ErrorCode.COUPON_PRESS_IS_EXIST);
} }
if (null != wxCouponCVo.getPressSupportIsNew() && EnumYesOrNo.YES.getCode().intValue() == wxCouponCVo.getPressSupportIsNew().intValue()) {
int orderCount = wxOrderService.countCouponConditionType1(tenantEntity.getTenantId(),memberId);
if (orderCount > 0) {
return new ResultData(ErrorCode.COUPON_PRESS_IS_EXIST.getCode(),"您进行过消费,无法参与新用户砍价.");
}
int pressCount = wxOrderPressService.userCount(tenantEntity, memberId);
if (pressCount > 0) {
return new ResultData(ErrorCode.COUPON_PRESS_IS_EXIST.getCode(),"您进行过砍价活动,无法参与新用户砍价.");
}
}
//验证砍价批次规则 //验证砍价批次规则
ResultData result = wxPressBatchService.checkBargainerPressBatchRule(order, memberId); ResultData result = wxPressBatchService.checkBargainerPressBatchRule(order, memberId);
if (Result.SUCCESS != result.code) { if (Result.SUCCESS != result.code) {


+ 3
- 0
mallinkService/src/main/java/com/iformall/domain/po/WxCoupon.java Просмотреть файл

@@ -181,6 +181,9 @@ public class WxCoupon extends TenantEntity {
@io.swagger.annotations.ApiModelProperty(value="砍价支付扣库存EnumYesOrNo",name="pressPayReduceStock") @io.swagger.annotations.ApiModelProperty(value="砍价支付扣库存EnumYesOrNo",name="pressPayReduceStock")
private Integer pressPayReduceStock; private Integer pressPayReduceStock;
@io.swagger.annotations.ApiModelProperty(value="砍价帮砍人数是否为新用户EnumYesOrNo",name="pressSupportIsNew")
private Integer pressSupportIsNew;


@io.swagger.annotations.ApiModelProperty(value="积分售价(适用于类型10,11)",name="creditPrice") @io.swagger.annotations.ApiModelProperty(value="积分售价(适用于类型10,11)",name="creditPrice")
private Integer creditPrice; private Integer creditPrice;


+ 4
- 0
mallinkService/src/main/java/com/iformall/service/WxOrderPressService.java Просмотреть файл

@@ -6,6 +6,7 @@ import com.iformall.domain.po.WxCUser;
import com.iformall.domain.po.WxCoupon; import com.iformall.domain.po.WxCoupon;
import com.iformall.domain.po.WxOrder; import com.iformall.domain.po.WxOrder;
import com.iformall.domain.po.WxOrderPress; import com.iformall.domain.po.WxOrderPress;
import com.iformall.domain.po.base.TenantEntity;


public interface WxOrderPressService { public interface WxOrderPressService {


@@ -57,5 +58,8 @@ public interface WxOrderPressService {
int pressCouponStatus(WxOrder order, Long cUserId); int pressCouponStatus(WxOrder order, Long cUserId);


boolean checkCUserHasJoin(WxOrder order, Long cUserId); boolean checkCUserHasJoin(WxOrder order, Long cUserId);
//用户参与砍价的次数
int userCount(TenantEntity tenantEntity,Long cUserId);
} }

+ 1
- 0
mallinkService/src/main/java/com/iformall/service/WxOrderService.java Просмотреть файл

@@ -270,4 +270,5 @@ public interface WxOrderService {
int updateCpsStatus(WxOrder order); int updateCpsStatus(WxOrder order);


ResultData handlerPushOrder(TenantEntity tenantEntity, Long composeOrderId, String batchExtParam, List<CreateOrderCallback.Good> goods); ResultData handlerPushOrder(TenantEntity tenantEntity, Long composeOrderId, String batchExtParam, List<CreateOrderCallback.Good> goods);

} }

+ 9
- 0
mallinkService/src/main/java/com/iformall/service/impl/WxOrderPressServiceImpl.java Просмотреть файл

@@ -7,6 +7,7 @@ import com.google.common.collect.Lists;
import com.iformall.common.ErrorCode; import com.iformall.common.ErrorCode;
import com.iformall.common.IdWorker; import com.iformall.common.IdWorker;
import com.iformall.domain.po.*; import com.iformall.domain.po.*;
import com.iformall.domain.po.base.TenantEntity;
import com.iformall.domain.po.msg.SmartAppMsg; import com.iformall.domain.po.msg.SmartAppMsg;
import com.iformall.enums.*; import com.iformall.enums.*;
import com.iformall.exception.MallinkException; import com.iformall.exception.MallinkException;
@@ -141,6 +142,14 @@ public class WxOrderPressServiceImpl implements WxOrderPressService {
} }
return EnumOrderPressStatus.NOT_JOIN.getCode(); return EnumOrderPressStatus.NOT_JOIN.getCode();
} }

@Override
public int userCount(TenantEntity tenantEntity, Long cUserId) {
WxOrderPress oq = new WxOrderPress();
oq.updateTenantInfo(oq);
oq.setUserId(cUserId);
return wxOrderPressMapper.findCount(oq);
}
} }

+ 14
- 2
mallinkService/src/main/resources/mapper/WxCouponMapper.xml Просмотреть файл

@@ -45,6 +45,7 @@
<result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/> <result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/>
<result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/> <result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/>
<result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/> <result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/>
<result column="press_support_is_new" jdbcType="INTEGER" property="pressSupportIsNew"/>
<result column="auto_refund" jdbcType="INTEGER" property="autoRefund"/> <result column="auto_refund" jdbcType="INTEGER" property="autoRefund"/>
<result column="credit_price" jdbcType="INTEGER" property="creditPrice"/> <result column="credit_price" jdbcType="INTEGER" property="creditPrice"/>
<result column="credit_refund" jdbcType="INTEGER" property="creditRefund"/> <result column="credit_refund" jdbcType="INTEGER" property="creditRefund"/>
@@ -111,6 +112,7 @@
<result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/> <result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/>
<result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/> <result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/>
<result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/> <result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/>
<result column="press_support_is_new" jdbcType="INTEGER" property="pressSupportIsNew"/>
<result column="auto_refund" jdbcType="INTEGER" property="autoRefund"/> <result column="auto_refund" jdbcType="INTEGER" property="autoRefund"/>


<result column="sale_count" property="saleCount"/> <result column="sale_count" property="saleCount"/>
@@ -132,7 +134,7 @@
c.`title`,c.`sub_title`,c.`item_group`,c.`sale_price`,c.`freight_price`,c.`use_price`,c.`use_limit_rule`,c.`use_limit_quantity`,c.`send_type`, c.`title`,c.`sub_title`,c.`item_group`,c.`sale_price`,c.`freight_price`,c.`use_price`,c.`use_limit_rule`,c.`use_limit_quantity`,c.`send_type`,
c.`valid_type`,c.`valid_start_date`,c.`valid_end_date`,c.pick_start_date,c.pick_end_date,c.`valid_days`,c.`detail`,c.`price`,c.tail_price,c.orig_price,c.`unit`,c.`remain_inventory`,c.`inventory`, c.`valid_type`,c.`valid_start_date`,c.`valid_end_date`,c.pick_start_date,c.pick_end_date,c.`valid_days`,c.`detail`,c.`price`,c.tail_price,c.orig_price,c.`unit`,c.`remain_inventory`,c.`inventory`,
c.`remark`,c.`status`,c.`create_date`,c.`update_date`,c.`business`,c.`sub_business`,c.`support_transfer`,c.`subsidy_num`,c.`subsidy_type`,c.`is_after_set_price`, c.`remark`,c.`status`,c.`create_date`,c.`update_date`,c.`business`,c.`sub_business`,c.`support_transfer`,c.`subsidy_num`,c.`subsidy_type`,c.`is_after_set_price`,
c.`press_limit_num`, c.`press_limit_hours`,c.`press_pay_reduce_stock`, c.`auto_refund`,c.`credit_price`,c.`credit_refund`,c.`put_apply_status`,c.`stock_apply_status`,c.`cancle_apply_status`,
c.`press_limit_num`, c.`press_limit_hours`,c.`press_pay_reduce_stock`,c.`press_support_is_new`, c.`auto_refund`,c.`credit_price`,c.`credit_refund`,c.`put_apply_status`,c.`stock_apply_status`,c.`cancle_apply_status`,
c.`conditions`,c.approval_type,c.content_type,c.source_type,c.merchant_type,c.password_support,c.is_recharge,c.used_password,c.gift_list,c.product_type,c.category_id,c.goods_id c.`conditions`,c.approval_type,c.content_type,c.source_type,c.merchant_type,c.password_support,c.is_recharge,c.used_password,c.gift_list,c.product_type,c.category_id,c.goods_id
</sql> </sql>


@@ -281,6 +283,10 @@
<if test=" null != pressPayReduceStock "> <if test=" null != pressPayReduceStock ">
and `press_pay_reduce_stock` = #{pressPayReduceStock} and `press_pay_reduce_stock` = #{pressPayReduceStock}
</if> </if>
<if test=" null != pressSupportIsNew ">
and `press_support_is_new` = #{pressSupportIsNew}
</if>


<if test=" null != autoRefund "> <if test=" null != autoRefund ">
and `auto_refund` = #{autoRefund} and `auto_refund` = #{autoRefund}
@@ -636,6 +642,10 @@
<if test=" null != pressPayReduceStock "> <if test=" null != pressPayReduceStock ">
and c.`press_pay_reduce_stock` = #{pressPayReduceStock} and c.`press_pay_reduce_stock` = #{pressPayReduceStock}
</if> </if>
<if test=" null != pressSupportIsNew ">
and c.`press_support_is_new` = #{pressSupportIsNew}
</if>


<if test=" null != autoRefund "> <if test=" null != autoRefund ">
and c.`auto_refund` = #{autoRefund} and c.`auto_refund` = #{autoRefund}
@@ -804,6 +814,7 @@
<result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/> <result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/>
<result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/> <result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/>
<result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/> <result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/>
<result column="press_support_is_new" jdbcType="INTEGER" property="pressSupportIsNew"/>
<result column="conditions" jdbcType="VARCHAR" property="conditions"/> <result column="conditions" jdbcType="VARCHAR" property="conditions"/>
<result column="content_type" jdbcType="INTEGER" property="contentType"/> <result column="content_type" jdbcType="INTEGER" property="contentType"/>
<result column="source_type" jdbcType="INTEGER" property="sourceType"/> <result column="source_type" jdbcType="INTEGER" property="sourceType"/>
@@ -857,6 +868,7 @@
<result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/> <result column="press_limit_num" jdbcType="INTEGER" property="pressLimitNum"/>
<result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/> <result column="press_limit_hours" jdbcType="INTEGER" property="pressLimitHours"/>
<result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/> <result column="press_pay_reduce_stock" jdbcType="INTEGER" property="pressPayReduceStock"/>
<result column="press_support_is_new" jdbcType="INTEGER" property="pressSupportIsNew"/>
<result column="conditions" jdbcType="VARCHAR" property="conditions"/> <result column="conditions" jdbcType="VARCHAR" property="conditions"/>
<result column="content_type" jdbcType="INTEGER" property="contentType"/> <result column="content_type" jdbcType="INTEGER" property="contentType"/>
<result column="source_type" jdbcType="INTEGER" property="sourceType"/> <result column="source_type" jdbcType="INTEGER" property="sourceType"/>
@@ -1354,7 +1366,7 @@
wc.tenant_id,wc.parent_tenant_id,wc.`type`,wc.`cover_img`,wc.`cover_picture`,wc.`detail_picture`,wc.`title`,wc.`sub_title`,wc.`item_group`,wc.`sale_price`,wc.`freight_price`,wc.`use_price`,wc.`use_limit_rule`,wc.`use_limit_quantity`,wc.`send_type`, wc.tenant_id,wc.parent_tenant_id,wc.`type`,wc.`cover_img`,wc.`cover_picture`,wc.`detail_picture`,wc.`title`,wc.`sub_title`,wc.`item_group`,wc.`sale_price`,wc.`freight_price`,wc.`use_price`,wc.`use_limit_rule`,wc.`use_limit_quantity`,wc.`send_type`,
wc.`valid_type`,wc.`valid_start_date`,wc.`valid_end_date`,wc.pick_start_date,wc.pick_end_date,wc.`valid_days`,wc.`detail`,wc.`price`,wc.tail_price,wc.orig_price,wc.`unit`,wc.`remain_inventory`,wc.`inventory`, wc.`valid_type`,wc.`valid_start_date`,wc.`valid_end_date`,wc.pick_start_date,wc.pick_end_date,wc.`valid_days`,wc.`detail`,wc.`price`,wc.tail_price,wc.orig_price,wc.`unit`,wc.`remain_inventory`,wc.`inventory`,
wc.`remark`,wc.`status`,wc.`create_date`,wc.`update_date`,wc.`business`,wc.`sub_business`,wc.`support_transfer`,wc.`subsidy_num`,wc.`subsidy_type`, wc.`remark`,wc.`status`,wc.`create_date`,wc.`update_date`,wc.`business`,wc.`sub_business`,wc.`support_transfer`,wc.`subsidy_num`,wc.`subsidy_type`,
wc.`press_limit_num`, wc.`press_limit_hours`,wc.`press_pay_reduce_stock`, wc.`auto_refund`,wc.`credit_price`,wc.`credit_refund`,wc.`conditions`,
wc.`press_limit_num`, wc.`press_limit_hours`,wc.`press_pay_reduce_stock`,wc.`press_support_is_new`, wc.`auto_refund`,wc.`credit_price`,wc.`credit_refund`,wc.`conditions`,
wc.title as couponName,wc.`cover_img` as couponPic,wc.`cover_picture` as couponPicture,wc.`detail_picture` as detailPicture,wc.id as couponId wc.title as couponName,wc.`cover_img` as couponPic,wc.`cover_picture` as couponPicture,wc.`detail_picture` as detailPicture,wc.id as couponId
from wx_coupon_channel ct from wx_coupon_channel ct
left join wx_coupon wc on wc.id = ct.coupon_id left join wx_coupon wc on wc.id = ct.coupon_id


Загрузка…
Отмена
Сохранить