package com.ruoyi.frequency.mallordergoods.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 订单商品对象 mall_order_goods
 *
 * @author liwenlong
 * @date 2024-01-25
 */
@Data
@Accessors(chain = true)
@TableName("mall_order_goods")
public class MallOrderGoods extends BaseEntity
{
    private static final long serialVersionUID = 1L;


    @ApiModelProperty("主键id")
    private Long id;

    @ApiModelProperty("删除标志;1正常 删除 3 禁用")
    private Integer delFlag;

    @ApiModelProperty("订单id")
    @Excel(name = "订单id")
    private Long orderId;

    @ApiModelProperty("商品id")
    @Excel(name = "商品id")
    private Long goodsId;

    @ApiModelProperty("规格id（如果是多规格;使用sku_id）")
    @Excel(name = "规格id", readConverterExp = "如=果是多规格;使用sku_id")
    private Long specId;

    @ApiModelProperty("购买数量")
    @Excel(name = "购买数量")
    private Integer buyNum;

    @ApiModelProperty("单价")
    @Excel(name = "单价")
    private BigDecimal unitPrice;

    @ApiModelProperty("购买时商品名称")
    @Excel(name = "购买时商品名称")
    private String goodsName;

    @ApiModelProperty("购买时规格名称")
    @Excel(name = "购买时规格名称")
    private String specName;

    @ApiModelProperty("购买时商品封面图")
    @Excel(name = "购买时商品封面图")
    private String goodsImage;

    @ApiModelProperty("购买时规格封面图")
    @Excel(name = "购买时规格封面图")
    private String specImage;

    @ApiModelProperty("购买时规格类型;1 单规格 2 多规格")
    @Excel(name = "购买时规格类型;1 单规格 2 多规格")
    private Integer specType;

    @ApiModelProperty("积分")
    @Excel(name = "积分")
    private BigDecimal unitIntegral;


    @ApiModelProperty("商品分类")
    @TableField(exist = false)
    private String goodsTypeName;



}
