You've already forked FrameTour-BE
- 在 VoucherBatchCreateReq、VoucherBatchResp 和 VoucherInfo 中添加适用商品类型列表字段 - 在 PriceVoucherBatchConfig 中添加适用商品类型列表字段,并使用 ProductTypeListTypeHandler 进行 JSON 序列化和反序列化 - 实现 ProductTypeListTypeHandler 以处理商品类型列表的 JSON 序列化和反序列化 - 更新 VoucherBatchServiceImpl 和 VoucherServiceImpl 以支持适用商品类型的筛选和计算
92 lines
1.4 KiB
Java
92 lines
1.4 KiB
Java
package com.ycwl.basic.pricing.dto;
|
|
|
|
import com.ycwl.basic.pricing.enums.ProductType;
|
|
import com.ycwl.basic.pricing.enums.VoucherDiscountType;
|
|
import lombok.Data;
|
|
|
|
import java.math.BigDecimal;
|
|
import java.util.Date;
|
|
import java.util.List;
|
|
|
|
/**
|
|
* 券码信息DTO
|
|
*/
|
|
@Data
|
|
public class VoucherInfo {
|
|
|
|
/**
|
|
* 券码ID
|
|
*/
|
|
private Long voucherId;
|
|
|
|
/**
|
|
* 券码
|
|
*/
|
|
private String voucherCode;
|
|
|
|
/**
|
|
* 批次ID
|
|
*/
|
|
private Long batchId;
|
|
|
|
/**
|
|
* 批次名称
|
|
*/
|
|
private String batchName;
|
|
|
|
/**
|
|
* 景区ID
|
|
*/
|
|
private Long scenicId;
|
|
|
|
/**
|
|
* 推客ID
|
|
*/
|
|
private Long brokerId;
|
|
|
|
/**
|
|
* 优惠类型
|
|
*/
|
|
private VoucherDiscountType discountType;
|
|
|
|
/**
|
|
* 优惠值
|
|
*/
|
|
private BigDecimal discountValue;
|
|
|
|
/**
|
|
* 实际优惠金额
|
|
*/
|
|
private BigDecimal actualDiscountAmount;
|
|
|
|
/**
|
|
* 状态
|
|
*/
|
|
private Integer status;
|
|
|
|
/**
|
|
* 领取时间
|
|
*/
|
|
private Date claimedTime;
|
|
|
|
/**
|
|
* 使用时间
|
|
*/
|
|
private Date usedTime;
|
|
|
|
/**
|
|
* 是否可用
|
|
*/
|
|
private Boolean available;
|
|
|
|
/**
|
|
* 不可用原因
|
|
*/
|
|
private String unavailableReason;
|
|
|
|
/**
|
|
* 适用商品类型列表
|
|
* null表示适用所有商品类型
|
|
*/
|
|
private List<ProductType> applicableProducts;
|
|
} |