package cn.com.qmth.stmms.common.domain;

import cn.com.qmth.stmms.biz.school.model.School;
import cn.com.qmth.stmms.biz.user.model.User;
import cn.com.qmth.stmms.common.enums.Role;

public class ApiUser {

    private Integer schoolId;

    private User userData;

    private School schoolData;

    private Role role;

    public ApiUser(School school) {
        schoolData = school;
        schoolId = school.getId();
        role = Role.SCHOOL_DEV;
    }

    public ApiUser(User user) {
        userData = user;
        schoolId = user.getSchoolId();
        role = user.getRole();
    }

    public Integer getSchoolId() {
        return schoolId;
    }

    public Role getRole() {
        return role;
    }

    public User getUserData() {
        return userData;
    }

    public School getSchoolData() {
        return schoolData;
    }

}
