package com.ltgk.boat.domain.entity;


import com.baomidou.mybatisplus.annotation.*;
import com.ltgk.common.core.page.BasePage;
import com.ltgk.common.validation.groups.Detail;
import com.ltgk.common.validation.groups.Update;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.Date;

/**
 * 终端设备表 (DsBoatDevice)实体类
 *
 * @author Qi ChengBin
 * @date 2025-03-05
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName(value = "ds_boat_device")
@ApiModel(value = "终端设备表对象", description = "DsBoatDevice表")
public class DsBoatDevice extends BasePage implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @NotBlank(message = "主键信息不能为空", groups = {Detail.class, Update.class})
    private String id;

    @ApiModelProperty(value = "船舶ID")
    @TableField(value = "boat_id")
    private String boatId;

    @ApiModelProperty(value = "船舶号")
    @TableField(value = "boat_name")
    private String boatName;

    @ApiModelProperty(value = "类型ID")
    @TableField(value = "type_id")
    private String typeId;

    @ApiModelProperty(value = "设备类型（北斗、AIS）")
    @TableField(value = "device_type")
    private String deviceType;

    @ApiModelProperty(value = "MMSI")
    @TableField(value = "mmsi")
    private String mmsi;

    @ApiModelProperty(value = "终端号与上边的MMSI 是一个，这个字段没用，")
    @TableField(value = "code")
    private String code;

    @ApiModelProperty(value = "设备类型")
    @TableField(value = "type")
    private String type;

    @ApiModelProperty(value = "命令字标志")
    @TableField(value = "cmd_sign")
    private String cmdSign;

    @ApiModelProperty(value = "创建日期")
    @TableField(value = "create_at")
    private Date createAt;

    @ApiModelProperty(value = "创建人")
    @TableField(value = "create_by")
    private String createBy;

    @ApiModelProperty(value = "编辑日期")
    @TableField(value = "update_at")
    private Date updateAt;

    @ApiModelProperty(value = "编辑人")
    @TableField(value = "update_by")
    private String updateBy;

    @ApiModelProperty(value = "删除标记")
    @TableField(value = "del_flag")
    @TableLogic(delval = "1", value = "0")
    private Integer delFlag;

    @ApiModelProperty(value = "备注")
    @TableField(value = "remarks")
    private String remarks;

    @ApiModelProperty(value = "终端号")
    @TableField(exist = false)
    private String terminalCode;
}

