package cn.estsh.i3plus.ext.mes.pcn.pojo.bean;

import cn.estsh.i3plus.ext.mes.pcn.pojo.util.MesPcnExtEnumUtil;
import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.ColumnDefault;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.*;

/**
 * @Description : WMS产线生成AGV任务配置表
 * @Reference :
 * @Author : jiaqi.hou
 * @CreateDate : 2023-01-09 17:25
 * @Modify:
 **/
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Inheritance(strategy = InheritanceType.JOINED)
@Table(name="SX_WORK_LINE_GENERATION_AGV_TASKS_CONFIG")
@Api("WMS产线生成AGV任务配置表-由WMS同步")
public class SxWorkLineGenerationAgvTasksConfig extends BaseBean {

    @Column(name = "WORK_CENTER_CODE")
    @ApiParam(value = "生产线代码")
    private String workCenterCode;

    @Column(name = "WORK_CENTER_NAME")
    @ApiParam(value = "产线名称")
    private String workCenterName;

    /**
     * 10:需要,20:不需要 默认需要
     */
    @Column(name = "IS_AGV_CARRY",columnDefinition = "int default 10")
    @ApiParam(value = "是否生成AGV任务")
    @AnnoOutputColumn(refClass = MesPcnExtEnumUtil.IS_AGV_CARRY.class,refForeignKey = "value", value = "description")
    private Integer isAGVCarry;

    @Column(name = "SYSTEM_SYNC_STATUS")
    @ColumnDefault("2")
    @ApiParam(value = "系统同步标志")
    public Integer systemSyncStatus = 2;

}
