From 91fa95119c5a62230fd67fe1c5948af78b478429 Mon Sep 17 00:00:00 2001 From: xhxu Date: Fri, 24 Sep 2021 16:49:55 +0800 Subject: [PATCH] wx_coupon_order add --- .../iformall/domain/vo/WxOrderCouponVo.java | 23 +++++++++++++++++++ .../resources/mapper/WxCouponOrderMapper.xml | 16 ++++++++++--- 2 files changed, 36 insertions(+), 3 deletions(-) diff --git a/mallinkService/src/main/java/com/iformall/domain/vo/WxOrderCouponVo.java b/mallinkService/src/main/java/com/iformall/domain/vo/WxOrderCouponVo.java index c3df7e84e..38f191bc3 100644 --- a/mallinkService/src/main/java/com/iformall/domain/vo/WxOrderCouponVo.java +++ b/mallinkService/src/main/java/com/iformall/domain/vo/WxOrderCouponVo.java @@ -2,10 +2,12 @@ package com.iformall.domain.vo; import com.baomidou.mybatisplus.annotation.TableField; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.iformall.common.SortColumn; import com.iformall.domain.po.base.TenantEntity; import lombok.Data; import lombok.EqualsAndHashCode; +import java.math.BigDecimal; import java.util.Date; import java.util.List; @@ -109,4 +111,25 @@ public class WxOrderCouponVo extends TenantEntity { @io.swagger.annotations.ApiModelProperty(value="组合订单编号",name="composeOrderId") private Long composeOrderId; + + @io.swagger.annotations.ApiModelProperty(value="运费",name="freightPrice") + private Integer freightPrice; + + @TableField(exist = false) + @SortColumn(column = "freight_price") + private String freightPriceStr; + + public String getFreightPriceStr() { + if(freightPrice!=null) { + freightPriceStr = new BigDecimal(freightPrice).divide(new BigDecimal(100)).toString(); + } + return freightPriceStr; + } + + @io.swagger.annotations.ApiModelProperty(value="收货地址",name="shippingAddress") + private String shippingAddress; + + @io.swagger.annotations.ApiModelProperty(value="配送类型 0:默认(无) 1:自提 2:配送",name="shippingType") + private Integer shippingType; + } diff --git a/mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml b/mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml index d83f94de1..c79bc0199 100644 --- a/mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml +++ b/mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml @@ -1268,9 +1268,19 @@ where 1=1 and co.coupon_id = c.id - and co.coupon_type != 5 - and co.coupon_type != 51 - and co.coupon_type < 100 + + + and co.coupon_type = #{couponType} + + + and co.coupon_type != 5 + and co.coupon_type != 11 + and co.coupon_type != 12 + and co.coupon_type != 51 + and co.coupon_type < 100 + + + and co.c_user_id = #{cUserId}