package com.haha.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

@Data
@TableName("t_user_coupon")
public class UserCoupon implements Serializable {
    private static final long serialVersionUID = 1L;

    @TableId(type = IdType.AUTO)
    private Long id;

    private String couponCode;

    private Long templateId;

    private Long userId;

    private Long orderId;

    private Integer status;

    private LocalDateTime receiveTime;

    private LocalDateTime useTime;

    private LocalDateTime validStartTime;

    private LocalDateTime validEndTime;

    private BigDecimal discountAmount;

    private LocalDateTime createTime;

    private LocalDateTime updateTime;

    @TableField(exist = false)
    private String couponName;

    @TableField(exist = false)
    private Integer couponType;

    @TableField(exist = false)
    private BigDecimal minAmount;

    @TableField(exist = false)
    private String statusLabel;

    @TableField(exist = false)
    private String statusColor;
}
