package jnpf.model.cultivate.v2.promotion.req;

import jnpf.model.cultivate.v2.position.vo.V2CultivatePositionDetailForApp;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.apache.commons.lang3.StringUtils;


@EqualsAndHashCode(callSuper = true)
@Data
public class V2CultivatePromotionPositionDetailForApp extends V2CultivatePositionDetailForApp {
    /**
     * 学习地图id
     */
    private String promotionId;
    /**
     * 阶段
     */
    private Integer level;


    public void checkParams() {

        if (StringUtils.isEmpty(promotionId)) {
            throw new RuntimeException("参数错误,学习地图id不能为空");
        }
        if (level == null) {
            throw new RuntimeException("参数错误,地图阶段不能为空");
        }
        super.checkParams();
    }
}
