package com.xisc.pm.domain.entity;

import java.math.BigDecimal;

import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

import com.fasterxml.jackson.annotation.JsonInclude;

import io.choerodon.mybatis.annotation.ModifyAudit;
import io.choerodon.mybatis.annotation.VersionAudit;
import io.choerodon.mybatis.domain.AuditDomain;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

/**
 * 板坯子板位置表
 *
 * @author jun.zeng 2024-11-21 11:05:34
 */
@Setter
@Getter
@ApiModel("板坯子板位置表")
@VersionAudit
@ModifyAudit
@JsonInclude(value = JsonInclude.Include.NON_NULL)
@Table(name = "PM_AUTO_PD_POSITION")
public class PmAutoPdPosition extends AuditDomain {

    public static final String FIELD_POSITION_ID = "positionId";
    public static final String FIELD_ORDER_NO = "orderNo";
    public static final String FIELD_ORDER_SEQ_NO = "orderSeqNo";
    public static final String FIELD_VIRTUAL_SLAB_NO = "virtualSlabNo";
    public static final String FIELD_PICK_MODE_WID_DIR = "pickModeWidDir";
    public static final String FIELD_PICK_MODE_LEN_DIR = "pickModeLenDir";
    public static final String FIELD_TENANT_ID = "tenantId";
    public static final String FIELD_OBJECT_VERSION_NUMBER = "objectVersionNumber";
    public static final String FIELD_CREATION_DATE = "creationDate";
    public static final String FIELD_CREATED_BY = "createdBy";
    public static final String FIELD_LAST_UPDATED_BY = "lastUpdatedBy";
    public static final String FIELD_LAST_UPDATE_DATE = "lastUpdateDate";
    public static final String FIELD_ATTRIBUTE1 = "attribute1";
    public static final String FIELD_ATTRIBUTE2 = "attribute2";
    public static final String FIELD_ATTRIBUTE3 = "attribute3";
    public static final String FIELD_ATTRIBUTE4 = "attribute4";
    public static final String FIELD_ATTRIBUTE5 = "attribute5";

    @ApiModelProperty("主键ID")
    @Id
    @GeneratedValue
    private Long positionId;
    @ApiModelProperty(value = "合同号", required = true)
    @NotBlank
    private String orderNo;
    @ApiModelProperty(value = "合同顺序号")
    private Long orderSeqNo;
    @ApiModelProperty(value = "虚拟板坯号")
    private String virtualSlabNo;
    @ApiModelProperty(value = "取板方式_宽度方向")
    private Long pickModeWidDir;
    @ApiModelProperty(value = "取板方式_长度方向")
    private Long pickModeLenDir;
    @ApiModelProperty(value = "租户ID", required = true)
    @NotNull
    private Long tenantId;
    @ApiModelProperty(value = "行版本号，用来处理锁", required = true)
    @NotNull
    private Long objectVersionNumber;
    
    @ApiModelProperty(value = "小板长", required = true)
    @Transient
    private BigDecimal orderLen ;
    
    @ApiModelProperty(value = "小板宽", required = true)
    @Transient
    private BigDecimal orderWidth ;

}
