package com.app.entity.basics;

import com.app.entity.BaseEntity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotEmpty;

/**
 * 功能描述：学校
 *
 * @Auther: 梁展鹏
 * @Date: 2018/7/17 14:03
 */
@ApiModel("学校")
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@TableName("t_school")
public class School extends BaseEntity {

    @ApiModelProperty("机构id")
    @NotEmpty
    @TableField(value = "organ_id")
    private String organId;

    @ApiModelProperty("学校名称")
    @TableField(value = "name")
    private String name;

    /**
     * 年级(1: 小学, 2: 中学, 3: 高中; 数据保存如: 1; 1,2; 1,2,3; 2,3)
     *
     * @see com.app.constant.SchoolConstant#PRIMARY_SCHOOL
     * @see com.app.constant.SchoolConstant#MIDDLE_SCHOOL
     * @see com.app.constant.SchoolConstant#HIGH_SCHOOL
     */
    @ApiModelProperty("年级")
    @NotEmpty
    @TableField("grade_year")
    private String gradeYear;

    @ApiModelProperty("省级名称")
    @NotEmpty
    @TableField("province")
    private String province;

    @ApiModelProperty("城市名称")
    @NotEmpty
    @TableField("city")
    private String city;

    @ApiModelProperty("行政区名称")
    @NotEmpty
    @TableField("area")
    private String area;

    @ApiModelProperty("备注")
    @TableField("remarks")
    private String remarks;

}
