package com.muyu.fault.common;

import cn.hutool.core.date.DateTime;
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.web.domain.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import lombok.experimental.SuperBuilder;

import java.util.Date;

@Data
@SuperBuilder
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "fault_log",autoResultMap = true)
@EqualsAndHashCode(callSuper = true)
public class FaultLog extends BaseEntity {
    /**
     * 日志ID
     */
    @TableId(value = "fault_log_id", type= IdType.AUTO)
    @Schema(defaultValue = "日志ID",type = "Long",description = "日志ID")
    private Long faultLogId;
    /**
     * 故障码
     */
    @Schema(defaultValue = "故障码",type = "String",description = "故障码")
    private String faultLogCodes;
    /**
     * 车辆VIN
     */
    @Schema(defaultValue = "车辆VIN",type = "String",description = "车辆VIN")
    private String faultLogVin;
    /**
     * 开始报警时间
     */
    @Schema(defaultValue = "开始报警时间",type = "Date",description = "开始报警时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date  faultLogStartTime;
    /**
     * 结束报警时间
     */
    @Schema(defaultValue = "结束报警时间",type = "Date",description = "结束报警时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date faultLogEndTime;
}
