package com.qmth.distributed.print.business.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qmth.teachcloud.common.base.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * <p>
 * 专业表
 * </p>
 *
 * @author xf
 * @since 2024-04-22
 */
@TableName("basic_professional")
@ApiModel(value = "BasicProfessional对象", description = "专业表")
public class BasicProfessional extends BaseEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(value = "学校ID")
    private Long schoolId;

    @NotBlank(message = "专业名称不能为空")
    @ApiModelProperty(value = "专业名称")
    private String name;

    @JsonSerialize(using = ToStringSerializer.class)
    @NotNull(message = "所属学院ID不能为空")
    @ApiModelProperty(value = "所属学院ID")
    private Long orgId;

    public Long getSchoolId() {
        return schoolId;
    }

    public void setSchoolId(Long schoolId) {
        this.schoolId = schoolId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Long getOrgId() {
        return orgId;
    }

    public void setOrgId(Long orgId) {
        this.orgId = orgId;
    }

    @Override
    public String toString() {
        return "BasicProfessional{" +
                ", name=" + name +
                ", orgId=" + orgId +
                "}";
    }
}
