# 学校API

# 获取当前用户的学校列表

# 请求路径

/school/v1/user-schools

# 请求方式

get

# 请求参数
# 返回结果
字段 字型 名称 字段解释
schoolId Long 学校Id
schoolName String 学校名称
schoolTypeId Long 学校学制类型Id
kind Integer 学校办学类型
address String 学校地址
schoolIntro String 学校介绍
province String
city String
district String
# 返回示例
{
    "code":200,
    "success":true,
    "data":[
        {
            "schoolId":4201130012,
            "schoolName":"武汉市汉南区化工总厂欣欣幼儿园",
            "schoolTypeId":1,
            "kind":0,
            "schoolIntro":"",
            "address":"",
            "province":null,
            "city":null,
            "district":null
        }
    ],
    "msg":"操作成功"
}

# 获取某个用户的学校列表

# 请求路径

/school/v1/querySchoolListByUserId

# 请求方式

get

# 请求参数
参数名 类型 名称 必填 说明
userId Long 用户id
# 返回结果
字段 字型 名称 字段解释
schoolId Long 学校Id
schoolName String 学校名称
schoolTypeId Long 学校学制类型Id
kind Integer 学校办学类型
address String 学校地址
schoolIntro String 学校介绍
province String
city String
district String
# 返回示例
{
    "code":200,
    "success":true,
    "data":[
        {
            "schoolId":4201130012,
            "schoolName":"武汉市汉南区化工总厂欣欣幼儿园",
            "schoolTypeId":1,
            "kind":0,
            "schoolIntro":"",
            "address":"",
            "province":null,
            "city":null,
            "district":null
        }
    ],
    "msg":"操作成功"
}

# 获取所有学段列表

# 请求路径

/school/v1/types

# 请求方式

get

# 请求参数

# 返回结果
字段 字型 名称 字段解释
schoolTypeId Long 学校学制Id
schoolTypeName String 学校学制名称
# 返回示例
    {
        "code": 200,
        "success": true,
        "data": [
            {
                "schoolTypeId": 4,
                "schoolTypeName": "高中"
            },
            {
                "schoolTypeId": 3,
                "schoolTypeName": "初中"
            },
            {
                "schoolTypeId": 2,
                "schoolTypeName": "小学"
            },
            {
                "schoolTypeId": 1,
                "schoolTypeName": "幼儿园"
            }
        ],
        "msg": "操作成功"
    }

# 分页获取学校教职工列表

# 请求路径

/school/v1/employees

# 请求方式

get

# 请求参数
参数名 类型 名称 必填 说明
schoolId Long 学校id
classTypeId Integer 班级类型id
pageIndex Integer 页码 如果不填,默认为1。必须大于0
pageSize Integer 每页返回多少数据 如果不填,默认为20。必须大于0,最大为50
# 返回结果
字段 字型 名称 字段解释
page 当前页码
total 总共多少页
pagesize 每页多少条数据
records 总共多少行数据
rows 具体的数据列行
字段 字型 名称 字段解释
userId Long 老师id
userName String 教师姓名
employeeNo String 员工工号
phone String 用户联系号码
# 请求示例

/school/v1/employees?schoolId=1&classTypeId=1

# 返回示例
{
    "code": 200,
    "success": true,
    "data": {
        "page": 1,
        "total": 2,
        "pagesize": 20,
        "records": 36,
        "rows": [
            {
                "userId": 5097826,
                "userName": "马瑛",
                "employeeNo": "2020144195",
                "phone": "18291885920"
            },
            {
                "userId": 5097806,
                "userName": "李波",
                "employeeNo": "2020529",
                "phone": "18089230125"
            },
            {
                "userId": 5097542,
                "userName": "小家电",
                "employeeNo": "2020142697",
                "phone": "17800000117"
            },
            {
                "userId": 5097507,
                "userName": "李佳恩呐",
                "employeeNo": "2020528",
                "phone": "17282828282"
            },
            {
                "userId": 5097402,
                "userName": "刘来事",
                "employeeNo": "2020526",
                "phone": "17200000043"
            },
            {
                "userId": 5096694,
                "userName": "李大霏",
                "employeeNo": "2020525",
                "phone": "17200000099"
            },
            {
                "userId": 5096864,
                "userName": "风头",
                "employeeNo": "2020523",
                "phone": "17900000119"
            },
            {
                "userId": 5097206,
                "userName": "小糖",
                "employeeNo": "2020136607",
                "phone": "17200000331"
            },
            {
                "userId": 5097200,
                "userName": "阿道夫2",
                "employeeNo": "2020522",
                "phone": "13756483646"
            },
            {
                "userId": 5096941,
                "userName": "检查出生日期",
                "employeeNo": "2020519",
                "phone": "13819239345"
            },
            {
                "userId": 5096933,
                "userName": "libo ",
                "employeeNo": "2020517",
                "phone": "18792598998"
            },
            {
                "userId": 5096646,
                "userName": "葛亮",
                "employeeNo": "2020515",
                "phone": "13810238356"
            },
            {
                "userId": 5096303,
                "userName": "孙老师",
                "employeeNo": "2020510",
                "phone": "15129858533"
            },
            {
                "userId": 5095289,
                "userName": "王大宝",
                "employeeNo": "2020488",
                "phone": "15800009995"
            },
            {
                "userId": 5095262,
                "userName": "小号的",
                "employeeNo": "2020484",
                "phone": "17896002299"
            },
            {
                "userId": 5093801,
                "userName": "鞠婧祎",
                "employeeNo": "2020482",
                "phone": "18790178888"
            },
            {
                "userId": 5093800,
                "userName": "爱上肖德福1",
                "employeeNo": "2020481",
                "phone": "17896009922"
            },
            {
                "userId": 5090994,
                "userName": "tom",
                "employeeNo": "2020021",
                "phone": "17629171998"
            },
            {
                "userId": 5083147,
                "userName": "葛亮",
                "employeeNo": "2020516",
                "phone": "13810238357"
            },
            {
                "userId": 5083077,
                "userName": "例鞥",
                "employeeNo": "2020514",
                "phone": "13810238355"
            }
        ]
    },
    "msg": "操作成功"
}

# 获取该校的学科列表

# 请求路径

/school/v1/subjects

# 请求方式

get

# 请求参数
参数名 类型 名称 必填 说明
schoolId Long 学校id
schoolTypeId Integer 学段id
# 返回结果
字段 字型 名称 字段解释
subjectId Long 学科id
subjectName String 学科名称
# 请求示例

/school/v1/subjects?schoolId=1&schoolTypeId=1

# 返回示例
{
    "code":200,
    "success":true,
    "data":[
        {
            "subjectId":2,
            "subjectName":"副园长"
        },
        {
            "subjectId":3,
            "subjectName":"主班老师"
        },
        {
            "subjectId":4,
            "subjectName":"配班老师"
        },
        {
            "subjectId":5,
            "subjectName":"保育员"
        },
        {
            "subjectId":6,
            "subjectName":"保安"
        },
        {
            "subjectId":7,
            "subjectName":"厨师"
        },
        {
            "subjectId":8,
            "subjectName":"保健医生"
        },
        {
            "subjectId":9,
            "subjectName":"招生老师"
        },
        {
            "subjectId":10,
            "subjectName":"教学主任"
        },
        {
            "subjectId":11,
            "subjectName":"后勤老师"
        },
        {
            "subjectId":12,
            "subjectName":"财务老师"
        },
        {
            "subjectId":13,
            "subjectName":"行政老师"
        },
        {
            "subjectId":14,
            "subjectName":"其他老师"
        }
    ],
    "msg":"操作成功"
}

# 获取该校的年级列表

# 请求路径

/school/v1/grades

# 请求方式

get

# 请求参数
参数名 类型 名称 必填 说明
schoolId Long 学校id
schoolTypeId Integer 学段id
pageIndex Integer 页码 如果不填,默认为1。必须大于0
pageSize Integer 每页返回多少数据 如果不填,默认为20。必须大于0,最大为50
# 返回结果
字段 字型 名称 字段解释
page 当前页码
total 总共多少页
pagesize 每页多少条数据
records 总共多少行数据
rows 具体的数据列行
字段 字型 名称 字段解释
schoolTypeId Integer 学段id
gradeId Long 年级id
schoolTypeName String 学校类型名
gradeName String 年级名字
schoolId Long 学校ID 0:表示全部通用
# 请求示例

/school/v1/grades?schoolId=1&schoolTypeId=1

# 返回示例
{
    "code":200,
    "success":true,
    "data":{
        "page":1,
        "total":2,
        "pagesize":10,
        "records":22,
        "rows":[
            {
                "schoolTypeId":2,
                "schoolTypeName":"小学",
                "gradeId":4,
                "gradeName":"一年级",
                "schoolId":0
            },
            {
                "schoolTypeId":2,
                "schoolTypeName":"小学",
                "gradeId":5,
                "gradeName":"二年级",
                "schoolId":0
            },
            {
                "schoolTypeId":2,
                "schoolTypeName":"小学",
                "gradeId":6,
                "gradeName":"三年级",
                "schoolId":0
            },
            {
                "schoolTypeId":2,
                "schoolTypeName":"小学",
                "gradeId":7,
                "gradeName":"四年级",
                "schoolId":0
            },
            {
                "schoolTypeId":2,
                "schoolTypeName":"小学",
                "gradeId":8,
                "gradeName":"五年级",
                "schoolId":0
            },
            {
                "schoolTypeId":2,
                "schoolTypeName":"小学",
                "gradeId":9,
                "gradeName":"六年级",
                "schoolId":0
            },
            {
                "schoolTypeId":3,
                "schoolTypeName":"初中",
                "gradeId":13,
                "gradeName":"初一年级",
                "schoolId":0
            },
            {
                "schoolTypeId":3,
                "schoolTypeName":"初中",
                "gradeId":14,
                "gradeName":"初二年级",
                "schoolId":0
            },
            {
                "schoolTypeId":3,
                "schoolTypeName":"初中",
                "gradeId":15,
                "gradeName":"初三年级",
                "schoolId":0
            },
            {
                "schoolTypeId":4,
                "schoolTypeName":"高中",
                "gradeId":16,
                "gradeName":"高一年级",
                "schoolId":0
            },
            {
                "schoolTypeId":4,
                "schoolTypeName":"高中",
                "gradeId":17,
                "gradeName":"高二年级",
                "schoolId":0
            },
            {
                "schoolTypeId":4,
                "schoolTypeName":"高中",
                "gradeId":18,
                "gradeName":"高三年级",
                "schoolId":0
            },
            {
                "schoolTypeId":1,
                "schoolTypeName":"学前班",
                "gradeId":19,
                "gradeName":"学前班",
                "schoolId":0
            },
            {
                "schoolTypeId":1,
                "schoolTypeName":"幼儿园",
                "gradeId":23,
                "gradeName":"小小托",
                "schoolId":0
            },
            {
                "schoolTypeId":1,
                "schoolTypeName":"幼儿园",
                "gradeId":21,
                "gradeName":"托",
                "schoolId":0
            },
            {
                "schoolTypeId":1,
                "schoolTypeName":"幼儿园",
                "gradeId":1,
                "gradeName":"小",
                "schoolId":0
            },
            {
                "schoolTypeId":1,
                "schoolTypeName":"幼儿园",
                "gradeId":2,
                "gradeName":"中",
                "schoolId":0
            },
            {
                "schoolTypeId":1,
                "schoolTypeName":"幼儿园",
                "gradeId":3,
                "gradeName":"大",
                "schoolId":0
            },
            {
                "schoolTypeId":13,
                "schoolTypeName":"中专",
                "gradeId":25,
                "gradeName":"中专",
                "schoolId":0
            },
            {
                "schoolTypeId":14,
                "schoolTypeName":"职高",
                "gradeId":26,
                "gradeName":"职高",
                "schoolId":0
            }
        ]
    },
    "msg":"操作成功"
}

#

# 通过userId查询老师信息

# 请求路径

/school/v1/userInfo

# 请求方式

get

# 请求参数

参数名 类型 名称 必填 说明
userId Long 用户id

# 返回结果

字段 字型 名称 字段解释
userId Long 用户id
userName String 用户名称
userIcon String 用户头像
userSex String 用户性别
phoneNum String 用户学号
externalUserNo String 用户编号

# 请求示例

/school/v1/userInfo?userId=1

# 调用成后返回如下

{
    "code": 200,
    "success": true,
    "data": {
        "userId": 119226,
        "userName": "张娜",
        "userIcon": "http://static.imzhiliao.com/1441516428152TOkCRW4BQs.jpg",
        "userSex": "女",
        "phoneNum": "18728482234",
        "externalUserNo": "119226"
    },
    "msg": "操作成功"
}

#

# 通过schoolId查询学校信息

# 请求路径

/school/v1/schoolInfo

# 请求方式

get

# 请求参数

参数名 类型 名称 必填 说明
schoolId Long 学校id

# 返回结果

字段 字型 名称 字段解释
schoolId Long 学校id
schoolName String 学校名称
schoolTypeIds List 学校学制类型 1 幼儿园
2 小学
3 初中
4 高中
11 学前办
12 托
13 中专职业
14 职高
15 中专
16 大学
kind Int 学校办学类型
schoolIntro String 学校简介
address String 学校地址
province String 省名
city String 市名
district String 区名

# 请求示例

/school/v1/schoolInfo?schoolId=130306004

# 调用成后返回如下

{
  
     "code": 200,
     "success": true,
     "data": {
       "schoolId": 130306004,
       "schoolName": "企业微信测试三小",
       "schoolTypeIds": [
         12,
         11,
         1,
         2,
         3,
         4,
         14
       ],
       "kind": 0,
       "address": "测试地址",
       "province": "河北省",
       "city": "秦皇岛市",
       "district": "抚宁区"
     },
     "msg": "操作成功"
   
}

# 通过schoolId查询超级管理员信息

# 请求路径

/school/v1/schoolMaster

# 请求方式

get

# 请求参数

参数名 类型 名称 必填 说明
schoolId Long 学校id

# 返回结果

字段 字型 名称 字段解释
schoolId Long 学校id
schoolName String 学校名称
userName String 管理员名称
userId Long 管理员id
phoneNumber String 管理员电话号码
userIcon String 管理员头像
Level Int 2:副管理员 3:管理员,此时返回的都是三

# 请求示例

/school/v1/schoolMaster?schoolId=1101010008

# 返回结果

{
    "code": 200,
    "success": true,
    "data": {
        "schoolId": 1101010008,
        "schoolName": "蚂蚁王国",
        "userName": "张妈妈",
        "userId": 267406,
        "phoneNumber": "1512111111",
        "userIcon": "",
        "level": 3
    },
    "msg": "操作成功"
}
Last Updated: 12/11/2020, 11:17:16 AM