You've already forked FrameTour-BE
- 使用自定义的 BundleProductListTypeHandler 替代 JacksonTypeHandler - 在 PriceBundleConfigMapper 中添加 @Results 注解,指定自定义处理器 - 更新 insert 和 update 方法,使用新的 BundleProductListTypeHandler
58 lines
1.3 KiB
Java
58 lines
1.3 KiB
Java
package com.ycwl.basic.pricing.entity;
|
|
|
|
import com.baomidou.mybatisplus.annotation.TableName;
|
|
import com.baomidou.mybatisplus.annotation.TableField;
|
|
import com.ycwl.basic.pricing.dto.BundleProductItem;
|
|
import com.ycwl.basic.pricing.handler.BundleProductListTypeHandler;
|
|
import lombok.Data;
|
|
import lombok.EqualsAndHashCode;
|
|
import org.apache.ibatis.type.JdbcType;
|
|
|
|
import java.math.BigDecimal;
|
|
import java.util.List;
|
|
|
|
/**
|
|
* 一口价配置实体
|
|
*/
|
|
@Data
|
|
@EqualsAndHashCode(callSuper = true)
|
|
@TableName("price_bundle_config")
|
|
public class PriceBundleConfig extends BaseEntity {
|
|
|
|
/**
|
|
* 套餐名称
|
|
*/
|
|
private String bundleName;
|
|
|
|
/**
|
|
* 景区ID
|
|
*/
|
|
private String scenicId;
|
|
|
|
/**
|
|
* 套餐价格
|
|
*/
|
|
private BigDecimal bundlePrice;
|
|
|
|
/**
|
|
* 包含商品
|
|
*/
|
|
@TableField(typeHandler = BundleProductListTypeHandler.class, jdbcType = JdbcType.VARCHAR)
|
|
private List<BundleProductItem> includedProducts;
|
|
|
|
/**
|
|
* 排除商品
|
|
*/
|
|
@TableField(typeHandler = BundleProductListTypeHandler.class, jdbcType = JdbcType.VARCHAR)
|
|
private List<BundleProductItem> excludedProducts;
|
|
|
|
/**
|
|
* 套餐描述
|
|
*/
|
|
private String description;
|
|
|
|
/**
|
|
* 是否启用
|
|
*/
|
|
private Boolean isActive;
|
|
} |