| package com.zy.asrs.entity; | 
|   | 
| import com.core.common.Cools;import com.baomidou.mybatisplus.annotations.TableId; | 
| import com.baomidou.mybatisplus.enums.IdType; | 
| import com.baomidou.mybatisplus.annotations.TableField; | 
| import java.text.SimpleDateFormat; | 
| import java.util.Date; | 
| import org.springframework.format.annotation.DateTimeFormat; | 
|   | 
| import io.swagger.annotations.ApiModelProperty; | 
| import lombok.Data; | 
| import com.baomidou.mybatisplus.annotations.TableName; | 
| import java.io.Serializable; | 
|   | 
| @Data | 
| @TableName("\"SOURCE\".\"wcs_device_error\"") | 
| public class DeviceError implements Serializable { | 
|   | 
|     private static final long serialVersionUID = 1L; | 
|   | 
|     @ApiModelProperty(value= "") | 
|     @TableId(value = "ID", type = IdType.AUTO) | 
|     @TableField("ID") | 
|     private Long id; | 
|   | 
|     /** | 
|      * 设备 | 
|      */ | 
|     @ApiModelProperty(value= "设备") | 
|     @TableField("DEVICE") | 
|     private String device; | 
|   | 
|     /** | 
|      * 异常信息 | 
|      */ | 
|     @ApiModelProperty(value= "异常信息") | 
|     @TableField("MSG") | 
|     private String msg; | 
|   | 
|     /** | 
|      * 设备ID | 
|      */ | 
|     @ApiModelProperty(value= "设备ID") | 
|     @TableField("DEVICE_ID") | 
|     private Integer deviceId; | 
|   | 
|     /** | 
|      * 创建时间 | 
|      */ | 
|     @ApiModelProperty(value= "创建时间") | 
|     @TableField("CREATE_TIME") | 
|     @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") | 
|     private Date createTime; | 
|   | 
|     public DeviceError() {} | 
|   | 
|     public DeviceError(Long id, String device, String msg, Integer deviceId, Date createTime) { | 
|         this.id = id; | 
|         this.device = device; | 
|         this.msg = msg; | 
|         this.deviceId = deviceId; | 
|         this.createTime = createTime; | 
|     } | 
|   | 
|     //    DeviceError deviceError = new DeviceError( | 
| //            null,    // 设备 | 
| //            null,    // 设备ID | 
| //            null,    // 创建时间 | 
| //            null    // 异常信息 | 
| //    ); | 
|   | 
|     public String getCreateTime$(){ | 
|         if (Cools.isEmpty(this.createTime)){ | 
|             return ""; | 
|         } | 
|         return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime); | 
|     } | 
|   | 
|   | 
| } |