package com.ltgk.boat.domain.dto;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.ltgk.common.core.page.BasePage;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 渔船进港信息传输参数对象
 *
 * @author Qi ChengBin
 * @date 2024-12-19
 */
@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "渔船进港信息传输参数对象", description = "渔船进港信息传输参数对象")
public class DsEnterPortDTO extends BasePage {
    @ApiModelProperty(value = "进港记录id 编辑时使用")
    @JsonProperty("id")
    private String id;

    @ApiModelProperty(value = "所属渔港id")
    @JsonProperty("portId")
    private String portId;

    @ApiModelProperty(value = "船舶id")
    @JsonProperty("boatId")
    private String boatId;

    @ApiModelProperty(value = "船名号")
    @JsonProperty("boatName")
    private String boatName;

    @ApiModelProperty(value = "进港时间")
    @JsonProperty("enterTime")
    @NotNull(message = "进港时间不能为空！")
    private String enterTime;

    @ApiModelProperty(value = "船长签字")
    @JsonProperty("captionSign")
    private String captionSign;

    @ApiModelProperty(value = "渔获种类")
    @JsonProperty("typesOfCatch")
    private String typesOfCatch;

    @ApiModelProperty(value = "渔获重量")
    @JsonProperty("catchWeight")
    private BigDecimal catchWeight;

    @ApiModelProperty(value = "船员ids")
    @NotNull(message = "船员申请信息不能为空！")
    @JsonProperty("crewIds")
    private String crewIds;

    @ApiModelProperty(value = "驻港员签名")
    @JsonProperty("personnelSign")
    private String personnelSign;

    @JsonProperty("outTime")
    @ApiModelProperty(value = "拟出港时间")
    private String outTime;

    @JsonProperty("estimatedArrivalPortAnchorageTime")
    @ApiModelProperty(value = "预计抵达码头所在锚地的时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date estimatedArrivalPortAnchorageTime;

    @ApiModelProperty(value = "申请泊区ID")
    @JsonProperty("areaId")
    private String areaId;

    @ApiModelProperty(value = "进港凭证")
    @JsonProperty("enterVoucher")
    @TableField("enter_voucher")
    private String enterVoucher;

    @ApiModelProperty(value = "船东名称")
    @JsonProperty("holderName")
    private String holderName;

    @ApiModelProperty(value = "船东电话")
    @JsonProperty("holderPhone")
    private String holderPhone;
}
