package com.qmth.sop.business.entity;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qmth.sop.common.contant.SystemConstant;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

/**
 * <p>
 * sop明细表
 * </p>
 *
 * @author wangliang
 * @since 2023-08-31
 */
@ApiModel(value = "TBSopInfoDetail对象", description = "sop明细表")
public class TBSopInfoDetail implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    @ApiModelProperty(value = "sop信息id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long sopInfoId;

    @ApiModelProperty(value = "大区经理id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long leadId;

    @ApiModelProperty(value = "区域负责人id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long regionUserId;

    @ApiModelProperty(value = "实施工程师id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long engineerUserId;

    @ApiModelProperty(value = "助理实施工程师id数组")
    private String assistantEngineerUserIds;

    @ApiModelProperty(value = "之后是否由区域协调人替换实施工程师，true：是，false：不是")
    private Boolean afterRegionToEnginess = false;

    public TBSopInfoDetail() {

    }

    public TBSopInfoDetail(Long sopInfoId, Long leadId) {
        this.id = SystemConstant.getDbUuid();
        this.sopInfoId = sopInfoId;
        this.leadId = leadId;
    }

    public TBSopInfoDetail(Long leadId, Long regionUserId, Long engineerUserId, String assistantEngineerUserIds) {
        this.id = SystemConstant.getDbUuid();
        this.leadId = leadId;
        this.regionUserId = regionUserId;
        this.engineerUserId = engineerUserId;
        this.assistantEngineerUserIds = assistantEngineerUserIds;
    }

    public void updateUserIdInfo(Long regionUserId, Long engineerUserId, String assistantEngineerUserIds) {
        this.regionUserId = regionUserId;
        this.engineerUserId = engineerUserId;
        this.assistantEngineerUserIds = assistantEngineerUserIds;
    }

    public Boolean getAfterRegionToEnginess() {
        return afterRegionToEnginess;
    }

    public void setAfterRegionToEnginess(Boolean afterRegionToEnginess) {
        this.afterRegionToEnginess = afterRegionToEnginess;
    }

    public Long getLeadId() {
        return leadId;
    }

    public void setLeadId(Long leadId) {
        this.leadId = leadId;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getSopInfoId() {
        return sopInfoId;
    }

    public void setSopInfoId(Long sopInfoId) {
        this.sopInfoId = sopInfoId;
    }

    public Long getRegionUserId() {
        return regionUserId;
    }

    public void setRegionUserId(Long regionUserId) {
        this.regionUserId = regionUserId;
    }

    public Long getEngineerUserId() {
        return engineerUserId;
    }

    public void setEngineerUserId(Long engineerUserId) {
        this.engineerUserId = engineerUserId;
    }

    public String getAssistantEngineerUserIds() {
        return assistantEngineerUserIds;
    }

    public void setAssistantEngineerUserIds(String assistantEngineerUserIds) {
        this.assistantEngineerUserIds = assistantEngineerUserIds;
    }
}
