| @@ -6,6 +6,7 @@ import com.simple.common.Result; | |||||
| import com.simple.common.ResultData; | import com.simple.common.ResultData; | ||||
| import com.simple.domain.po.WxCUser; | import com.simple.domain.po.WxCUser; | ||||
| import com.simple.domain.po.WxCouponOrder; | import com.simple.domain.po.WxCouponOrder; | ||||
| import com.simple.domain.vo.WxCouponOrderCVo; | |||||
| import com.simple.exception.MallinkException; | import com.simple.exception.MallinkException; | ||||
| import com.simple.service.WxCouponOrderService; | import com.simple.service.WxCouponOrderService; | ||||
| import io.swagger.annotations.Api; | import io.swagger.annotations.Api; | ||||
| @@ -56,7 +57,6 @@ public class WxCouponOrderController extends BaseController { | |||||
| } | } | ||||
| } | } | ||||
| @ApiOperation("分页列表接口") | @ApiOperation("分页列表接口") | ||||
| @GetMapping("list") | @GetMapping("list") | ||||
| @ApiImplicitParams({ | @ApiImplicitParams({ | ||||
| @@ -65,12 +65,7 @@ public class WxCouponOrderController extends BaseController { | |||||
| @ApiImplicitParam(name = "couponOrderStatus", value="券状态状态:0,待使用 1,已核销 2,已过期 3,已作废", dataType="int", paramType = "query",required=false) | @ApiImplicitParam(name = "couponOrderStatus", value="券状态状态:0,待使用 1,已核销 2,已过期 3,已作废", dataType="int", paramType = "query",required=false) | ||||
| }) | }) | ||||
| public ResultData list(Integer couponOrderStatus, Integer pageNum, Integer pageSize) { | public ResultData list(Integer couponOrderStatus, Integer pageNum, Integer pageSize) { | ||||
| WxCUser user = getUser(); | |||||
| WxCouponOrder wxCouponOrder = new WxCouponOrder(); | |||||
| wxCouponOrder.setTenantId(user.getTenantId()); | |||||
| wxCouponOrder.setCouponOrderStatus(couponOrderStatus); | |||||
| final PageInfo<WxCouponOrder> page = wxCouponOrderService.listAsPage(wxCouponOrder, pageNum, pageSize); | |||||
| return new ResultData(page); | |||||
| return wxCouponOrderService.listCUserVoAsPage(getUser().getId(), couponOrderStatus, pageNum, pageSize); | |||||
| } | } | ||||
| @ApiOperation(value = "根据id查询接口", notes = "{\"couponOrderId\":\"string\"}") | @ApiOperation(value = "根据id查询接口", notes = "{\"couponOrderId\":\"string\"}") | ||||
| @@ -2,7 +2,7 @@ package com.simple.domain.vo; | |||||
| import com.simple.domain.po.WxCouponOrder; | import com.simple.domain.po.WxCouponOrder; | ||||
| public class WxCouponOrderCVo extends WxCouponOrder{ | |||||
| public class WxCouponOrderBVo extends WxCouponOrder{ | |||||
| /** | /** | ||||
| * | * | ||||
| @@ -0,0 +1,309 @@ | |||||
| package com.simple.domain.vo; | |||||
| import com.simple.domain.po.WxCouponOrder; | |||||
| import javax.persistence.Id; | |||||
| import javax.persistence.Transient; | |||||
| import java.util.Date; | |||||
| import java.util.List; | |||||
| public class WxCouponOrderCVo extends WxCouponOrder{ | |||||
| /** | |||||
| * | |||||
| */ | |||||
| private static final long serialVersionUID = 6687954932922444531L; | |||||
| @Id | |||||
| protected Long id; | |||||
| @Transient | |||||
| protected List<Long> ids; | |||||
| @Transient | |||||
| protected String sortColumns; | |||||
| public Long getId() { | |||||
| return id; | |||||
| } | |||||
| public void setId(Long id) { | |||||
| this.id = id; | |||||
| } | |||||
| public String getSortColumns() { | |||||
| return sortColumns; | |||||
| } | |||||
| public List<Long> getIds() { | |||||
| return ids; | |||||
| } | |||||
| public void setIds(List<Long> ids) { | |||||
| this.ids = ids; | |||||
| } | |||||
| /* 基础购买到的券信息 */ | |||||
| /***/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "", name = "tenantId") | |||||
| private String tenantId; | |||||
| /*单张券ID**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "单张券ID", name = "couponId") | |||||
| private Long couponId; | |||||
| /*c端用户id**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "c端用户id", name = "cUserId") | |||||
| private Long cUserId; | |||||
| /*操作券B端小程序用户ID**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "操作券B端小程序用户ID", name = "bUserId") | |||||
| private Long bUserId; | |||||
| /*用户订单ID**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "用户订单ID", name = "orderId") | |||||
| private Long orderId; | |||||
| /*该订单对应券的实际过期时间**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "该订单对应券的实际过期时间 ", name = "expiredTime") | |||||
| private Date expiredTime; | |||||
| /*状态:0,待使用 1,已核销 2,已过期 3,已作废 **/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "状态:0,待使用 1,已核销 2,已过期 3,已作废 ", name = "couponOrderStatus") | |||||
| private Integer couponOrderStatus; | |||||
| /***/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "", name = "createDate") | |||||
| private Date createDate; | |||||
| /***/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "", name = "updateDate") | |||||
| private Date updateDate; | |||||
| /*单券实际购买价格**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value = "单券实际购买价格", name = "couponPrice") | |||||
| private Integer couponPrice; | |||||
| /* 券类型信息 */ | |||||
| /*商户id**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="商户id",name="merchantId") | |||||
| private Long merchantId; | |||||
| /*券类型(1.满减券,2.代金券,3.团购券,4.礼品券,5.停车券)**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="券类型(1.满减券,2.代金券,3.团购券,4.礼品券,5.停车券)",name="type") | |||||
| private Integer type; | |||||
| /*封面图**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="封面图",name="coverImg") | |||||
| private String coverImg; | |||||
| /*券名称**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="券名称",name="title") | |||||
| private String title; | |||||
| /*副标题**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="副标题",name="subTitle") | |||||
| private String subTitle; | |||||
| /*售价(适用于类型2,3,4,5)**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="售价(适用于类型2,3,4,5)",name="salePrice") | |||||
| private Integer salePrice; | |||||
| /*使用条件金额(适用于类型1,2,3,4)**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="使用条件金额(适用于类型1,2,3,4)",name="usePrice") | |||||
| private Integer usePrice; | |||||
| /*面额**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="面额",name="price") | |||||
| private Integer price; | |||||
| /*须知**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="须知",name="detail") | |||||
| private String detail; | |||||
| /*购买须知**/ | |||||
| @io.swagger.annotations.ApiModelProperty(value="购买须知",name="remark") | |||||
| private String remark; | |||||
| public String getTenantId() { | |||||
| return tenantId; | |||||
| } | |||||
| public void setTenantId(String _tenantId) { | |||||
| tenantId = _tenantId; | |||||
| } | |||||
| public Long getCouponId() { | |||||
| return couponId; | |||||
| } | |||||
| public void setCouponId(Long _couponId) { | |||||
| couponId = _couponId; | |||||
| } | |||||
| public Long getCUserId() { | |||||
| return cUserId; | |||||
| } | |||||
| public void setCUserId(Long _cUserId) { | |||||
| cUserId = _cUserId; | |||||
| } | |||||
| public Long getBUserId() { | |||||
| return bUserId; | |||||
| } | |||||
| public void setBUserId(Long _bUserId) { | |||||
| bUserId = _bUserId; | |||||
| } | |||||
| public Long getOrderId() { | |||||
| return orderId; | |||||
| } | |||||
| public void setOrderId(Long _orderId) { | |||||
| orderId = _orderId; | |||||
| } | |||||
| public Date getExpiredTime() { | |||||
| return expiredTime; | |||||
| } | |||||
| public void setExpiredTime(Date _expiredTime) { | |||||
| expiredTime = _expiredTime; | |||||
| } | |||||
| public Integer getCouponOrderStatus() { | |||||
| return couponOrderStatus; | |||||
| } | |||||
| public void setCouponOrderStatus(Integer _couponOrderStatus) { | |||||
| couponOrderStatus = _couponOrderStatus; | |||||
| } | |||||
| public Date getCreateDate() { | |||||
| return createDate; | |||||
| } | |||||
| public void setCreateDate(Date _createDate) { | |||||
| createDate = _createDate; | |||||
| } | |||||
| public Date getUpdateDate() { | |||||
| return updateDate; | |||||
| } | |||||
| public void setUpdateDate(Date _updateDate) { | |||||
| updateDate = _updateDate; | |||||
| } | |||||
| public Integer getCouponPrice() { | |||||
| return couponPrice; | |||||
| } | |||||
| public void setCouponPrice(Integer _couponPrice) { | |||||
| couponPrice = _couponPrice; | |||||
| } | |||||
| public Long getMerchantId() { | |||||
| return merchantId; | |||||
| } | |||||
| public void setMerchantId(Long _merchantId) { | |||||
| merchantId = _merchantId; | |||||
| } | |||||
| public Integer getType() { | |||||
| return type; | |||||
| } | |||||
| public void setType(Integer _type) { | |||||
| type = _type; | |||||
| } | |||||
| public String getCoverImg() { | |||||
| return coverImg; | |||||
| } | |||||
| public void setCoverImg(String _coverImg) { | |||||
| coverImg = _coverImg; | |||||
| } | |||||
| public String getTitle() { | |||||
| return title; | |||||
| } | |||||
| public void setTitle(String _title) { | |||||
| title = _title; | |||||
| } | |||||
| public String getSubTitle() { | |||||
| return subTitle; | |||||
| } | |||||
| public void setSubTitle(String _subTitle) { | |||||
| subTitle = _subTitle; | |||||
| } | |||||
| public Integer getSalePrice() { | |||||
| return salePrice; | |||||
| } | |||||
| public void setSalePrice(Integer _salePrice) { | |||||
| salePrice = _salePrice; | |||||
| } | |||||
| public Integer getUsePrice() { | |||||
| return usePrice; | |||||
| } | |||||
| public void setUsePrice(Integer _usePrice) { | |||||
| usePrice = _usePrice; | |||||
| } | |||||
| public String getDetail() { | |||||
| return detail; | |||||
| } | |||||
| public void setDetail(String _detail) { | |||||
| detail = _detail; | |||||
| } | |||||
| public Integer getPrice() { | |||||
| return price; | |||||
| } | |||||
| public void setPrice(Integer _price) { | |||||
| price = _price; | |||||
| } | |||||
| public String getRemark() { | |||||
| return remark; | |||||
| } | |||||
| public void setRemark(String _remark) { | |||||
| remark = _remark; | |||||
| } | |||||
| public static enum Field { | |||||
| Id_ASC("`id` ASC"), Id_DESC("`id` DESC"), | |||||
| TenantId_ASC("`tenantId` ASC"), | |||||
| TenantId_DESC("`tenantId` DESC"), | |||||
| CouponId_ASC("`couponId` ASC"), | |||||
| CouponId_DESC("`couponId` DESC"), | |||||
| CUserId_ASC("`cUserId` ASC"), | |||||
| CUserId_DESC("`cUserId` DESC"), | |||||
| BUserId_ASC("`bUserId` ASC"), | |||||
| BUserId_DESC("`bUserId` DESC"), | |||||
| OrderId_ASC("`orderId` ASC"), | |||||
| OrderId_DESC("`orderId` DESC"), | |||||
| ExpiredTime_ASC("`expiredTime` ASC"), | |||||
| ExpiredTime_DESC("`expiredTime` DESC"), | |||||
| CouponOrderStatus_ASC("`couponOrderStatus` ASC"), | |||||
| CouponOrderStatus_DESC("`couponOrderStatus` DESC"), | |||||
| CreateDate_ASC("`createDate` ASC"), | |||||
| CreateDate_DESC("`createDate` DESC"), | |||||
| UpdateDate_ASC("`updateDate` ASC"), | |||||
| UpdateDate_DESC("`updateDate` DESC"), | |||||
| CouponPrice_ASC("`couponPrice` ASC"), | |||||
| CouponPrice_DESC("`couponPrice` DESC"); | |||||
| private String value; | |||||
| Field(String value) { | |||||
| this.value = value; | |||||
| } | |||||
| public String getValue() { | |||||
| return value; | |||||
| } | |||||
| public void setCol(String value) { | |||||
| this.value = value; | |||||
| } | |||||
| @Override | |||||
| public String toString() { | |||||
| return this.getValue(); | |||||
| } | |||||
| } | |||||
| public void setSortColumns(WxCouponOrder.Field... fields) { | |||||
| if (fields == null || fields.length == 0) { | |||||
| return; | |||||
| } | |||||
| for (int k = 0; k < fields.length; k++) { | |||||
| if (fields[k] == null) { | |||||
| return; | |||||
| } | |||||
| } | |||||
| StringBuilder sb = new StringBuilder(fields[0].toString()); | |||||
| for (int k = 1; k < fields.length; k++) { | |||||
| sb.append(","); | |||||
| sb.append(fields[k].toString()); | |||||
| } | |||||
| } | |||||
| public void setSortColumns(String sortColumns) { | |||||
| if (sortColumns == null || "".equals(sortColumns.trim())) { | |||||
| return; | |||||
| } | |||||
| if (sortColumns.contains(",")) { | |||||
| String[] cols = sortColumns.split(","); | |||||
| java.util.List<WxCouponOrder.Field> fList = new java.util.ArrayList(); | |||||
| for (int k = 0; k < cols.length; k++) { | |||||
| fList.add(WxCouponOrder.Field.valueOf(cols[k])); | |||||
| } | |||||
| this.setSortColumns(fList.toArray(new WxCouponOrder.Field[fList.size()])); | |||||
| } else { | |||||
| this.setSortColumns(WxCouponOrder.Field.valueOf(sortColumns)); | |||||
| } | |||||
| } | |||||
| } | |||||
| @@ -2,6 +2,7 @@ package com.simple.mapper; | |||||
| import java.util.*; | import java.util.*; | ||||
| import com.simple.common.CommonMapper; | import com.simple.common.CommonMapper; | ||||
| import com.simple.domain.vo.WxCouponOrderCVo; | |||||
| import org.apache.ibatis.annotations.Param; | import org.apache.ibatis.annotations.Param; | ||||
| import com.simple.domain.po.WxCouponOrder; | import com.simple.domain.po.WxCouponOrder; | ||||
| @@ -12,4 +13,6 @@ public interface WxCouponOrderMapper extends CommonMapper<WxCouponOrder, Long> { | |||||
| List<WxCouponOrder> findListOfUnverifiedByDate(Map dateMap); | List<WxCouponOrder> findListOfUnverifiedByDate(Map dateMap); | ||||
| List<WxCouponOrder> findListOfVerifiedByDate(Map dateMap); | List<WxCouponOrder> findListOfVerifiedByDate(Map dateMap); | ||||
| List<WxCouponOrderCVo> findListOfCUser(Map paramMap); | |||||
| } | } | ||||
| @@ -69,11 +69,16 @@ public interface WxCouponOrderService { | |||||
| /** | /** | ||||
| * 根据日期 b用户查券list | * 根据日期 b用户查券list | ||||
| * | * | ||||
| * @param bUserId 退券(款)人(登录用户) | |||||
| * @param bUserId B端用户) | |||||
| */ | */ | ||||
| ResultData listOnDateAsPage(Long bUserId, String date, Integer pageIndex, Integer pageSize, boolean isVerified); | ResultData listOnDateAsPage(Long bUserId, String date, Integer pageIndex, Integer pageSize, boolean isVerified); | ||||
| /** | |||||
| * 根据日期 b用户查券list | |||||
| * | |||||
| * @param bUserId B端用户 | |||||
| */ | |||||
| ResultData listCUserVoAsPage(Long cUserId, Integer pageIndex, Integer pageSize, Integer status); | |||||
| } | } | ||||
| @@ -7,13 +7,11 @@ import com.simple.common.IdWorker; | |||||
| import com.simple.common.Result; | import com.simple.common.Result; | ||||
| import com.simple.common.ResultData; | import com.simple.common.ResultData; | ||||
| import com.simple.domain.po.*; | import com.simple.domain.po.*; | ||||
| import com.simple.domain.vo.WxCouponOrderCVo; | |||||
| import com.simple.enums.EnumCouponOrderStatus; | import com.simple.enums.EnumCouponOrderStatus; | ||||
| import com.simple.enums.EnumCouponStatus; | import com.simple.enums.EnumCouponStatus; | ||||
| import com.simple.exception.MallinkException; | import com.simple.exception.MallinkException; | ||||
| import com.simple.mapper.WxMerchantMapper; | |||||
| import com.simple.mapper.WxOrderMapper; | |||||
| import com.simple.mapper.WxCouponOrderMapper; | |||||
| import com.simple.mapper.WxMerchantBUserMapper; | |||||
| import com.simple.mapper.*; | |||||
| import com.simple.service.WxCouponOrderService; | import com.simple.service.WxCouponOrderService; | ||||
| import org.apache.log4j.Logger; | import org.apache.log4j.Logger; | ||||
| import org.springframework.beans.factory.annotation.Autowired; | import org.springframework.beans.factory.annotation.Autowired; | ||||
| @@ -41,6 +39,9 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||||
| @Autowired | @Autowired | ||||
| WxMerchantBUserMapper wxMerchantBUserMapper; | WxMerchantBUserMapper wxMerchantBUserMapper; | ||||
| @Autowired | |||||
| WxCUserMapper wxCUserMapper; | |||||
| @Override | @Override | ||||
| public PageInfo<WxCouponOrder> listAsPage(WxCouponOrder record, Integer pageIndex, Integer pageSize) { | public PageInfo<WxCouponOrder> listAsPage(WxCouponOrder record, Integer pageIndex, Integer pageSize) { | ||||
| return PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxCouponOrderMapper.findList(record)); | return PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxCouponOrderMapper.findList(record)); | ||||
| @@ -77,7 +78,6 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||||
| } | } | ||||
| @Override | @Override | ||||
| public ResultData listOnDateAsPage(Long bUserId, String date, Integer pageIndex, Integer pageSize, boolean isVerified) { | public ResultData listOnDateAsPage(Long bUserId, String date, Integer pageIndex, Integer pageSize, boolean isVerified) { | ||||
| @@ -93,7 +93,6 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||||
| throw new MallinkException(ErrorCode.MERCHANT_INFO_NOT_FOUND); | throw new MallinkException(ErrorCode.MERCHANT_INFO_NOT_FOUND); | ||||
| } | } | ||||
| SimpleDateFormat fmt = new SimpleDateFormat("yyyy-MM-dd"); | SimpleDateFormat fmt = new SimpleDateFormat("yyyy-MM-dd"); | ||||
| String dateString; | String dateString; | ||||
| Date startDate; | Date startDate; | ||||
| @@ -150,6 +149,24 @@ public class WxCouponOrderServiceImpl implements WxCouponOrderService { | |||||
| } | } | ||||
| @Override | |||||
| public ResultData listCUserVoAsPage(Long cUserId, Integer status, Integer pageIndex, Integer pageSize) { | |||||
| WxCUser wxCuser = wxCUserMapper.selectByPrimaryKey(cUserId); | |||||
| if(wxCuser == null){ | |||||
| logger.error("用户不存在:"+ cUserId); | |||||
| throw new MallinkException(ErrorCode.USER_IS_EMPTY); | |||||
| } | |||||
| Map paramMap = new HashMap(); | |||||
| paramMap.put("cUserId", cUserId); | |||||
| paramMap.put("tenantId", wxCuser.getTenantId()); | |||||
| if (status != null) | |||||
| paramMap.put("status", status); | |||||
| return new ResultData(PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxCouponOrderMapper.findListOfCUser(paramMap))); | |||||
| } | |||||
| @Override | @Override | ||||
| @Transactional(propagation = Propagation.REQUIRED, readOnly = false, rollbackFor = {Exception.class}) | @Transactional(propagation = Propagation.REQUIRED, readOnly = false, rollbackFor = {Exception.class}) | ||||
| @@ -121,4 +121,50 @@ | |||||
| </select> | </select> | ||||
| <sql id="allCUserCouponOrderListColumns"> | |||||
| c.id,c.expired_time,c.coupon_order_status,c.create_date,c.update_date,c.coupon_price, | |||||
| co.cover_img,co.title,co.sub_title,co.sale_price,co.use_price,co.price | |||||
| </sql> | |||||
| <sql id="allCUserCouponOrderDetailColumns"> | |||||
| c.id,c.tenant_id,c.coupon_id,c.c_user_id,c.b_user_id,c.order_id,c.expired_time,c.coupon_order_status,c.create_date,c.update_date,c.coupon_price | |||||
| co.merchant_id,co.type,co.cover_img,co.title,co.sub_title,co.sale_price,co.use_price,co.price,co.detail,co.remark | |||||
| </sql> | |||||
| <resultMap id="CVoResultMap" type="com.simple.domain.vo.WxCouponOrderCVo"> | |||||
| <id column="id" jdbcType="BIGINT" property="id" /> | |||||
| <result column="tenant_id" jdbcType="BIGINT" property="tenantId" /> | |||||
| <result column="coupon_id" jdbcType="BIGINT" property="couponId" /> | |||||
| <result column="c_user_id" jdbcType="BIGINT" property="cUserId" /> | |||||
| <result column="b_user_id" jdbcType="BIGINT" property="bUserId" /> | |||||
| <result column="order_id" jdbcType="BIGINT" property="orderId" /> | |||||
| <result column="expired_time" jdbcType="TIMESTAMP" property="expiredTime" /> | |||||
| <result column="coupon_order_status" jdbcType="INTEGER" property="couponOrderStatus" /> | |||||
| <result column="create_date" jdbcType="TIMESTAMP" property="createDate" /> | |||||
| <result column="update_date" jdbcType="TIMESTAMP" property="updateDate" /> | |||||
| <result column="coupon_price" jdbcType="INTEGER" property="couponPrice" /> | |||||
| <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | |||||
| <result column="type" jdbcType="INTEGER" property="type" /> | |||||
| <result column="cover_img" jdbcType="VARCHAR" property="coverImg" /> | |||||
| <result column="title" jdbcType="VARCHAR" property="title" /> | |||||
| <result column="sub_title" jdbcType="VARCHAR" property="subTitle" /> | |||||
| <result column="sale_price" jdbcType="INTEGER" property="salePrice" /> | |||||
| <result column="use_price" jdbcType="INTEGER" property="usePrice" /> | |||||
| <result column="detail" jdbcType="VARCHAR" property="detail" /> | |||||
| <result column="price" jdbcType="INTEGER" property="price" /> | |||||
| <result column="remark" jdbcType="VARCHAR" property="remark" /> | |||||
| </resultMap> | |||||
| <select id="findListOfCUser" parameterType="map" resultMap="CVoResultMap"> | |||||
| select <include refid="allCUserCouponOrderListColumns" /> from wx_coupon_order c,wx_coupon co | |||||
| where c.c_user_id = #{cUserId} and c.tenant_id = #{tenantId} and c.coupon_id = co.id | |||||
| <if test="status != null"> | |||||
| AND c.coupon_order_status = #{status} | |||||
| </if> | |||||
| </select> | |||||
| </mapper> | </mapper> | ||||