package com.ruoyi.demo.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import lombok.Data;

import java.time.LocalDateTime;

@Data
@TableName("dl_order")
public class Order {
    @TableField("order_id")
    private String orderId;
    @TableField("goods_id")
    private String goodsId;
    @TableField("goods_name")
    private String goodsName;
    @TableField("specs")
    private String specs;
    @TableField("goods_price")
    private Float goodsPrice;
    @TableField("total_price")
    private Float totalPrice;
    @TableField("state")
    private String state;
    @TableField("user_id")
    private String userId;
    @TableField("user_name")
    private String userName;
    @TableField("user_telephone")
    private String userTelephone;
    @TableField("commercial_id")
    private String commercialId;
    @TableField("commercial_name")
    private String commercialName;
    @TableField("appkey")
    private String appkey;
    @TableField("app_name")
    private String appName;
    @TableField("create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    private LocalDateTime createTime;
    @TableField("show_delete")
    private Integer showDelete;
}
