import request from '@/utils/request'

// 3.1 1-2老师申请班主任
export function applyTeacherForm(data) {
	return request({
		url: '/front/form/applyTeacherForm',
		method: 'post',
		data: data
	})
}

// 3.3.1 查询学校配置
export function getSchoolParams() {
	return request({
		url: '/front/form/getSchoolParams',
		method: 'post'
	})
}

// 3.3.2 更新审批规则
export function updateSchoolAudit(data) {
	return request({
		url: '/front/form/updateSchoolAudit',
		method: 'post',
		data: data
	})
}

//3.2 验证班级成员
export function getClassMembers(params) {
	return request({
		url: '/front/form/getClassMembers',
		method: 'get',
		params: params
	})
}

// 3.4 更新选班时间
export function updateSchoolClass(data) {
	return request({
		url: '/front/form/updateSchoolClass',
		method: 'post',
		data: data
	})
}

// 3.7 用户申请表单
export function getUserForms(params) {
	return request({
		url: '/front/form/getUserForms',
		method: 'get',
		params: params
	})
}

// 3.5 校长取待审批列表
export function getForms(params) {
	return request({
		url: '/front/form/getForms',
		method: 'get',
		params: params
	})
}

// 3.6 校长审阅表单
export function commitForm(data) {
	return request({
		url: '/front/form/commitForm',
		method: 'post',
		data: data
	})
}

//3.8 撤回申请
///front/form/recallForm 02 撤回申请
export function recallForm(formId) {
	return request({
		url: '/front/form/recallForm',
		method: 'post',
		params: {
			formId
		}
	})
}
