package com.muyu.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.muyu.common.core.annotation.Excel;
import com.muyu.common.core.web.domain.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * @Author：ChenYan
 * @Project：2112-car-cloud-server
 * @Package：com.muyu.fault.domain
 * @Filename：FaultLog
 * @Description TODO
 * @Date：2024/9/16 20:11
 */
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
@TableName(value = "fault_log", autoResultMap = true)
public class FaultLog{

    /**
     * id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 故障码
     */
    @Excel(name = "故障码")
    private String faultCode;

    /**
     * 车辆VIN
     */
    @Excel(name = "车辆VIN")
    private String vin;

    /**
     * 开始报警时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:dd:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "开始报警时间", width = 30, dateFormat = "yyyy-MM-dd HH:dd:ss")
    private Date warningTime;

    /**
     * 结束报警时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:dd:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "结束报警时间", width = 30, dateFormat = "yyyy-MM-dd HH:dd:ss")
    private Date normalTime;

}
