import { request } from '../utils/request'

/**
 * @description 获取赛事阶段
 * @param { number }  competitionId  写死的 任意值 1
 */

export function getCompetitionList(parmas) {
    return request({
        url: `/agent/miniprogram/competitionStage`,
        method: 'GET',
        query: parmas
    })
}


/**
 * @description 查询云大赛报名的学校
 * @param { number }  stageId 大赛阶段id
 * 
 */

export function getCloudSchool(parmas) {
    return request({
        url: `/agent/miniprogram/competition/cloud/signup/info/school`,
        method: 'GET',
        query: parmas
    })
}


/**
 * @description 查询云大赛报名的学校
 * @param { number }  stageId 大赛阶段id
 * @param { number }  schoolId 学校id
 * 
 */

export function getCloudBaby(parmas) {
    return request({
        url: `/agent/miniprogram/competition/cloud/signup/info/baby`,
        method: 'GET',
        query: parmas
    })
}


/**
 * @description 获取大赛开始与结束时间
 * @param { number }  competitionId 大赛阶段id
 * 
 */

export function getCompetitionDate(parmas) {
    return request({
        url: `/agent/miniprogram/competition/startTime`,
        method: 'GET',
        query: parmas
    })
}




export function getMock(parmas) {
    return request({
        url: `school`,
        method: 'GET',
        query: parmas
    })
}



/**
 * @description 获取赛事id
 * 
 */

export function getCompetitionId() {
    return request({
        url: `/agent/miniprogram/competition/id`,
        method: 'GET'
    })
}


/**
 * @description 获取全部赛事
 * 
 */

export function getAllCompetition() {
    return request({
        url: `/agent/miniprogram/competition/all`,
        method: 'GET'
    })
}

/**
 * @description 提交海选报名
 * 
 */
export function submitAgentRegister(data) {
    return request({
        url: `/agent/miniprogram/agent/register`,
        method: 'POST',
        query: data
    })
}


/**
 * @description 我的报名列表-分页
 * 
 */
export function getAgentRegisterListByPage(parmas) {
    return request({
        url: `/agent/miniprogram/agent/register/page`,
        method: 'GET',
        query: parmas
    })
}


/**
 * @description 报名详情
 * 
 */
export function getAgentRegisterDetail(parmas) {
    return request({
        url: `/agent/miniprogram/agent/register/detail`,
        method: 'GET',
        query: parmas
    })
}

/**
 * @description 参赛学校列表
 * 
 */
export function getAgentRegisterSchoolList(parmas) {
    return request({
        url: `/agent/miniprogram/agent/register/school`,
        method: 'GET',
        query: parmas
    })
}

/**
 * @description 纲领邮寄地址
 * 
 */
export function getAgentProgramAddress() {
    return request({
        url: `/agent/miniprogram/agent/program/address`,
        method: 'GET',
    })
}

// 查询上一次报名基本信息
export function getAgentRegisterLastInfo() {
    return request({
        url: `/agent/miniprogram/agent/register/last/info`,
        method: 'GET',
    })
}