package jnpf.model.cultivate.vo.promotion;

import jnpf.model.cultivate.po.promotion.FtbCultivatePromotionNew;
import lombok.Data;

import java.util.List;

/**
 * @Title: FtbCultivateStudyMemberVO
 * @Author: peng.hao
 * @create: 2024/4/7 14:31
 */
@Data
public class FtbCultivateStudyMemberVO {
    /**
     * 学习地图主键id
     */
    private String id;

    /**
     * 学习地图名称
     */
    private String promotion;

    /**
     * 学习地图ID，生成规则见原型
     */
    private String promotionBusinessId;

    /**
     *  学习地图设置(1是,0否)
     * 岗位考试与岗位实操鉴定合格后才能进入下一阶段 (v1.2)
     */
    private Integer learningMapSetting;

    /**
     * 通道分级岗位
     */
    private List<FtbCultivatePromotionPostNewVO> postChannelLevel;

    public static FtbCultivateStudyMemberVO coverFtbCultivateStudyMemberVO(FtbCultivatePromotionNew promotionNew) {
        if (promotionNew == null) {
            return null;
        }
        FtbCultivateStudyMemberVO ftbCultivateStudyMemberVO = new FtbCultivateStudyMemberVO();
        ftbCultivateStudyMemberVO.setPromotion(promotionNew.getPromotion());
        ftbCultivateStudyMemberVO.setPromotionBusinessId(promotionNew.getPromotionBusinessId());
        ftbCultivateStudyMemberVO.setLearningMapSetting(promotionNew.getLearningMapSetting());
        ftbCultivateStudyMemberVO.setId(promotionNew.getId());
        return ftbCultivateStudyMemberVO;
    }
}
