package com.qmth.teachcloud.common.bean.dto;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qmth.teachcloud.common.bean.result.SysUserResult;
import com.qmth.teachcloud.common.config.DictionaryConfig;
import com.qmth.teachcloud.common.enums.OrgTypeEnum;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotNull;
import java.util.ArrayList;
import java.util.List;

/**
 * @Date: 2021/3/29.
 */
public class OrgDto {

    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;
    private String schoolId;
    private String code;
    private String name;

    @JsonSerialize(using = ToStringSerializer.class)
    private Long parentId;
    private Boolean enable;

    @ApiModelProperty(value = "类型，COLLEGE：学院，FACULTY：院系，TEACHING_ROOM：教研室，PRINTING_HOUSE：印刷厂")
    private String type;

    private List<OrgDto> children = new ArrayList<>();

    @ApiModelProperty(value = "机构下系统用户")
    private List<SysUserResult> sysUserList;

    @ApiModelProperty(value = "校区id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long campusId;

    @ApiModelProperty(value = "校区名称")
    private String campusName;

    @ApiModelProperty(value = "校区编码")
    private String campusCode;

    public String getCampusCode() {
        return campusCode;
    }

    public void setCampusCode(String campusCode) {
        this.campusCode = campusCode;
    }

    public String getCampusName() {
        return campusName;
    }

    public void setCampusName(String campusName) {
        this.campusName = campusName;
    }

    public Long getCampusId() {
        return campusId;
    }

    public void setCampusId(Long campusId) {
        this.campusId = campusId;
    }

    public Long getId() {
        return id;
    }

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

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getSchoolId() {
        return schoolId;
    }

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

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getName() {
        return name;
    }

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

    public Long getParentId() {
        return parentId;
    }

    public void setParentId(Long parentId) {
        this.parentId = parentId;
    }

    public Boolean getEnable() {
        return enable;
    }

    public void setEnable(Boolean enable) {
        this.enable = enable;
    }

    public List<OrgDto> getChildren() {
        return children;
    }

    public void setChildren(List<OrgDto> children) {
        this.children = children;
    }

    public List<SysUserResult> getSysUserList() {
        return sysUserList;
    }

    public void setSysUserList(List<SysUserResult> sysUserList) {
        this.sysUserList = sysUserList;
    }
}
