2024-07-26 18:59:02 +08:00
|
|
|
|
<template>
|
|
|
|
|
|
<div class="app-container">
|
|
|
|
|
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="110px">
|
2024-08-20 18:02:46 +08:00
|
|
|
|
<el-form-item label="学校名称" prop="schoolName">
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-input v-model="queryParams.schoolName" placeholder="请输入学校名称" clearable
|
|
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
|
|
/>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</el-form-item>
|
2024-08-20 18:02:46 +08:00
|
|
|
|
<el-form-item label="学院名称" prop="collegeName">
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-input v-model="queryParams.collegeName" placeholder="请输入学院名称" clearable
|
|
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
|
|
/>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="所属赛区" prop="division">
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-input v-model="queryParams.division" placeholder="请输入所属赛区" clearable
|
|
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
|
|
/>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="团队名称" prop="teamName">
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-input v-model="queryParams.teamName" placeholder="请输入团队名称" clearable
|
|
|
|
|
|
@keyup.enter.native="handleQuery"
|
|
|
|
|
|
/>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
</el-form-item>
|
2025-02-11 17:56:19 +08:00
|
|
|
|
<el-form-item label="年份" prop="year">
|
|
|
|
|
|
<el-date-picker
|
|
|
|
|
|
v-model="queryParams.year"
|
|
|
|
|
|
type="year"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
placeholder="选择年份"
|
|
|
|
|
|
>
|
2025-02-11 17:56:19 +08:00
|
|
|
|
</el-date-picker>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</el-form-item>
|
2025-05-24 14:22:40 +08:00
|
|
|
|
<el-form-item label="赛道" prop="year">
|
|
|
|
|
|
<el-select v-model="queryParams.racetrack" placeholder="请选择" clearable>
|
|
|
|
|
|
<el-option
|
|
|
|
|
|
v-for="item in dict.type.com_racetrack"
|
|
|
|
|
|
:key="item.value"
|
|
|
|
|
|
:label="item.label"
|
|
|
|
|
|
:value="item.value">
|
|
|
|
|
|
</el-option>
|
|
|
|
|
|
</el-select>
|
|
|
|
|
|
</el-form-item>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<!-- <el-form-item label="大赛年份" prop="competitionYear">-->
|
|
|
|
|
|
<!-- <el-select v-model="queryParams.createTime" placeholder="请选择">-->
|
|
|
|
|
|
<!-- <el-option v-for="item in yearList" :key="item.value" :label="item.label" :value="item.value">-->
|
|
|
|
|
|
<!-- </el-option>-->
|
|
|
|
|
|
<!-- </el-select>-->
|
|
|
|
|
|
<!-- </el-form-item>-->
|
2024-07-26 18:59:02 +08:00
|
|
|
|
<el-form-item>
|
|
|
|
|
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
2024-07-30 09:25:39 +08:00
|
|
|
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置刷新</el-button>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</el-form-item>
|
|
|
|
|
|
</el-form>
|
|
|
|
|
|
|
|
|
|
|
|
<el-row :gutter="10" class="mb8">
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-col :span="1.5">
|
|
|
|
|
|
<el-button
|
|
|
|
|
|
type="info"
|
|
|
|
|
|
plain
|
|
|
|
|
|
icon="el-icon-upload2"
|
|
|
|
|
|
size="mini"
|
|
|
|
|
|
@click="handleImport('student')"
|
|
|
|
|
|
v-hasPermi="['hit:hitRegInfoUser:import']"
|
|
|
|
|
|
>导入学生成绩
|
|
|
|
|
|
</el-button>
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="1.5">
|
|
|
|
|
|
<el-button
|
|
|
|
|
|
type="info"
|
|
|
|
|
|
plain
|
|
|
|
|
|
icon="el-icon-upload2"
|
|
|
|
|
|
size="mini"
|
|
|
|
|
|
@click="handleImport('team')"
|
|
|
|
|
|
v-hasPermi="['hit:hitRegInfoTeam:import']"
|
|
|
|
|
|
>导入团队成绩
|
|
|
|
|
|
</el-button>
|
|
|
|
|
|
</el-col>
|
2024-10-08 10:54:15 +08:00
|
|
|
|
<el-col :span="1.5">
|
2024-07-26 18:59:02 +08:00
|
|
|
|
<el-button
|
|
|
|
|
|
type="warning"
|
|
|
|
|
|
plain
|
|
|
|
|
|
icon="el-icon-download"
|
|
|
|
|
|
size="mini"
|
|
|
|
|
|
@click="handleExport"
|
2024-07-29 16:42:21 +08:00
|
|
|
|
v-hasPermi="['hit:hitRegistrationStudentInfo:export']"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
>导出
|
|
|
|
|
|
</el-button>
|
2024-10-08 10:54:15 +08:00
|
|
|
|
</el-col>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-col :span="1.5" v-hasPermi="['hit:open']">
|
2024-10-18 17:06:53 +08:00
|
|
|
|
<el-switch v-model="registerStatus" @change="updateRegisterStatus" active-value="1" inactive-value="0"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
active-text="开启报名" inactive-text="关闭报名"
|
|
|
|
|
|
>
|
2024-10-18 17:06:53 +08:00
|
|
|
|
</el-switch>
|
|
|
|
|
|
</el-col>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-table style="width: 100%; table-layout: auto" v-loading="loading" :data="HitRegistrationStudentInfoList"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
@selection-change="handleSelectionChange"
|
|
|
|
|
|
>
|
2024-08-20 18:02:46 +08:00
|
|
|
|
|
2024-07-27 18:02:04 +08:00
|
|
|
|
<el-table-column type="expand">
|
|
|
|
|
|
<template slot-scope="props">
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-descriptions :title="'领队老师'" style="margin-left: 10%">
|
|
|
|
|
|
<el-descriptions-item label="老师姓名">{{ props.row.ldTeacher.teacherName }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师职务">{{ props.row.ldTeacher.teacherJob }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师手机号">{{ props.row.ldTeacher.teacherNumber }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师邮箱">{{ props.row.ldTeacher.teacherEmail }}</el-descriptions-item>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-descriptions-item label="老师所在系及专业">{{
|
|
|
|
|
|
props.row.ldTeacher.teacherSchool
|
|
|
|
|
|
}}
|
|
|
|
|
|
</el-descriptions-item>
|
2024-07-27 18:02:04 +08:00
|
|
|
|
</el-descriptions>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-descriptions :title="'指导老师' + (index)" v-for="(item, index) in props.row.zdTeacher"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
style="margin-left: 10%"
|
|
|
|
|
|
>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-descriptions-item label="老师姓名">{{ item.teacherName }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师职务">{{ item.teacherJob }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师手机号">{{ item.teacherNumber }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师邮箱">{{ item.teacherEmail }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="老师所在系及专业">{{ item.teacherSchool }}</el-descriptions-item>
|
2024-07-27 18:02:04 +08:00
|
|
|
|
</el-descriptions>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-descriptions :title="'学生信息' + (index + 1)" v-for="(item, index) in props.row.studentUserss"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
style="margin-left: 10%"
|
|
|
|
|
|
>
|
2024-08-20 18:02:46 +08:00
|
|
|
|
<!-- <el-descriptions-item label="比赛名称">{{props.row.competitionName}}</el-descriptions-item>-->
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-descriptions-item label="学生姓名">{{ item.stuName }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="学生性别">{{ item.sex }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="学生专业">{{ item.major }}</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="学生手机号">{{ item.phoneNumber }}</el-descriptions-item>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-descriptions-item label="虚拟赛成绩"><span style="color:red;">{{ item.virtualScore }}</span>
|
|
|
|
|
|
</el-descriptions-item>
|
|
|
|
|
|
<el-descriptions-item label="化验赛成绩"><span style="color:red;">{{ item.assayScore }}</span>
|
|
|
|
|
|
</el-descriptions-item>
|
2024-09-28 13:37:00 +08:00
|
|
|
|
<el-descriptions-item label="附件" v-if="item.dsFile">
|
|
|
|
|
|
<el-link :href="`${baseUrl}${item.dsFile}`" type="primary" :underline="false" target="_blank">
|
|
|
|
|
|
<span class="el-icon-document"> 下载 </span>
|
|
|
|
|
|
</el-link>
|
|
|
|
|
|
</el-descriptions-item>
|
2024-08-03 20:30:55 +08:00
|
|
|
|
</el-descriptions>
|
2024-08-20 18:02:46 +08:00
|
|
|
|
|
2024-07-27 18:02:04 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<!-- <el-table-column label="比赛名称" align="center" prop="competitionName" />-->
|
|
|
|
|
|
<el-table-column label="大赛年份" align="center" prop="year">
|
2024-08-21 18:47:25 +08:00
|
|
|
|
<template slot-scope="props">
|
2024-09-11 13:49:59 +08:00
|
|
|
|
{{ props.row.createTime.substring(0, 4) }}
|
2024-08-21 18:47:25 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-table-column label="所属赛区" align="center" prop="division"/>
|
|
|
|
|
|
<el-table-column label="学校名称" align="center" prop="schoolName"/>
|
|
|
|
|
|
<el-table-column label="院系名称" align="center" prop="collegeName"/>
|
|
|
|
|
|
<el-table-column label="团队名称" align="center" prop="teamName"/>
|
2025-05-24 14:22:40 +08:00
|
|
|
|
<el-table-column label="赛道" align="center" prop="racetrackLabel" width="180px"/>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-table-column label="盲样邮寄地址" align="center" prop="sampleAddress"/>
|
|
|
|
|
|
<el-table-column label="收件人" align="center" prop="sampleConcat"/>
|
|
|
|
|
|
<el-table-column label="联系电话" align="center" prop="sampleNumber"/>
|
|
|
|
|
|
<el-table-column label="分数" align="center" prop="score"/>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-table-column label="附件" align="center" prop="uploadFile">
|
2024-08-20 18:02:46 +08:00
|
|
|
|
<template slot-scope="props">
|
|
|
|
|
|
<el-link :href="`${baseUrl}${props.row.uploadFile}`" type="primary" :underline="false" target="_blank">
|
|
|
|
|
|
<span class="el-icon-document"> 下载 </span>
|
|
|
|
|
|
</el-link>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
2025-05-24 14:22:40 +08:00
|
|
|
|
<el-table-column label="报名时间" align="center" prop="createTime" width="100px">
|
2024-08-20 18:02:46 +08:00
|
|
|
|
<template slot-scope="props">
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{{ props.row.createTime.substring(0, 10) }}
|
2024-08-20 18:02:46 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
2024-09-21 13:49:15 +08:00
|
|
|
|
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-table-column label="审核状态" align="center" prop="auditStatus">
|
2024-08-20 18:02:46 +08:00
|
|
|
|
<template slot-scope="props">
|
2024-09-21 14:16:15 +08:00
|
|
|
|
<div v-if="props.row.auditStatus == '0' " style="color:#007bff;"> 待审核</div>
|
|
|
|
|
|
<div v-if="props.row.auditStatus == '1' " style="color:green;"> 通过</div>
|
|
|
|
|
|
<div v-if="props.row.auditStatus == '2' " style="color:red;"> 拒绝</div>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<div
|
|
|
|
|
|
v-if="props.row.registrationInformation && props.row.registrationInformation.status == '0' && props.row.zdTeacherList.includes(userId) && techerType == '0' && props.row.auditStatus == '9'"
|
|
|
|
|
|
style="color:#007bff;"
|
|
|
|
|
|
> 待确认
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div
|
|
|
|
|
|
v-if="props.row.registrationInformation && props.row.registrationInformation.status == '1' && props.row.zdTeacherList.includes(userId) && techerType == '0' && props.row.auditStatus == '9'"
|
|
|
|
|
|
style="color:green;"
|
|
|
|
|
|
> 已同意
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div
|
|
|
|
|
|
v-if="props.row.registrationInformation && props.row.registrationInformation.status == '2' && props.row.zdTeacherList.includes(userId) && techerType == '0' && props.row.auditStatus == '9'"
|
|
|
|
|
|
style="color:red;"
|
|
|
|
|
|
> 已拒绝
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<!--&& props.row.zdTeacherList.includes(userId)-->
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
2024-08-20 18:02:46 +08:00
|
|
|
|
|
2024-09-25 13:23:11 +08:00
|
|
|
|
<el-table-column label="赛事" align="center" class-name="small-padding fixed-width">
|
|
|
|
|
|
<template slot-scope="props">
|
|
|
|
|
|
{{ props.row.competitionName }}
|
|
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
|
2024-08-20 18:02:46 +08:00
|
|
|
|
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
|
<el-popconfirm title="确定当前操作?"
|
2024-09-21 14:16:15 +08:00
|
|
|
|
v-if="techerType != '0' && (scope.row.auditStatus == '0' || scope.row.auditStatus == '2')"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
@confirm="auditData(scope.row, '1')"
|
|
|
|
|
|
>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-button size="mini" type="text" slot="reference">通过</el-button>
|
2024-08-20 18:02:46 +08:00
|
|
|
|
</el-popconfirm>
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-popconfirm title="确定当前操作?" style="margin-left: 10px"
|
2024-09-21 14:16:15 +08:00
|
|
|
|
v-if="techerType != '0' && (scope.row.auditStatus == '0' || scope.row.auditStatus == '1')"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
@confirm="auditData(scope.row, '2')"
|
|
|
|
|
|
>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-button size="mini" type="text" slot="reference">拒绝</el-button>
|
2024-09-11 09:28:32 +08:00
|
|
|
|
</el-popconfirm>
|
|
|
|
|
|
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<!-- 指导老师 -->
|
2025-02-11 17:56:19 +08:00
|
|
|
|
<!---->
|
2024-09-21 13:49:15 +08:00
|
|
|
|
<el-popconfirm title="确定当前操作"
|
2024-10-14 18:33:48 +08:00
|
|
|
|
@confirm="submitData(scope.row.registrationInformation,1)"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
v-if="techerType == '0' && (scope.row.zdTeacherList) && scope.row.zdTeacherList.includes(userId) && scope.row.auditStatus == '9'"
|
|
|
|
|
|
>
|
2024-10-14 18:33:48 +08:00
|
|
|
|
<el-button size="mini" type="text" slot="reference">同意</el-button>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
</el-popconfirm>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<!---->
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-popconfirm title="确定当前操作?" style="margin-left: 10px"
|
2025-02-11 17:56:19 +08:00
|
|
|
|
v-if="techerType == '0' && (scope.row.zdTeacherList ) && scope.row.zdTeacherList.includes(userId) && scope.row.auditStatus == '9'"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
@confirm="submitData(scope.row.registrationInformation,2)"
|
|
|
|
|
|
>
|
2024-09-11 13:49:59 +08:00
|
|
|
|
<el-button size="mini" type="text" slot="reference">拒绝</el-button>
|
2024-09-11 09:28:32 +08:00
|
|
|
|
</el-popconfirm>
|
|
|
|
|
|
|
2024-10-14 18:33:48 +08:00
|
|
|
|
<!-- 修改团队信息 -->
|
|
|
|
|
|
<el-button size="mini" type="text" style="margin-left: 10px" @click="editData(scope.row)">修改</el-button>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
</el-table-column>
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</el-table>
|
|
|
|
|
|
|
2024-10-14 18:33:48 +08:00
|
|
|
|
<!-- 修改团队信息弹出层 对话框 -->
|
|
|
|
|
|
<el-dialog :visible.sync="editDialogVisible" title="编辑信息">
|
|
|
|
|
|
<el-form :model="currentRow">
|
2025-05-24 14:22:40 +08:00
|
|
|
|
<!-- <el-form-item label="所属赛区">-->
|
|
|
|
|
|
<!-- <el-input v-model="currentRow.division"></el-input>-->
|
|
|
|
|
|
<!-- </el-form-item>-->
|
|
|
|
|
|
<el-form-item label="所属赛区" prop="division">
|
|
|
|
|
|
<el-select v-model="currentRow.division" filterable allow-create default-first-option
|
|
|
|
|
|
placeholder="请选择所属赛区"
|
|
|
|
|
|
>
|
|
|
|
|
|
<el-option v-for="item in dict.type.com_region" :key="item.value" :label="item.label"
|
|
|
|
|
|
:value="item.value"
|
|
|
|
|
|
>
|
|
|
|
|
|
</el-option>
|
|
|
|
|
|
</el-select>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="赛道" prop="racetrackArr">
|
|
|
|
|
|
<el-checkbox-group v-model="currentRow.racetrackArr" @change="changeUpdateTeamRacetrack()">
|
|
|
|
|
|
<el-checkbox
|
|
|
|
|
|
v-for="item in dict.type.com_racetrack"
|
|
|
|
|
|
:key="item.value"
|
|
|
|
|
|
:label="item.value"
|
|
|
|
|
|
:checked="checked" @change="checked=!checked"
|
|
|
|
|
|
>
|
|
|
|
|
|
{{ item.label }}
|
|
|
|
|
|
</el-checkbox>
|
|
|
|
|
|
</el-checkbox-group>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="赛事" prop="competition" v-if="showCompetition">
|
|
|
|
|
|
<el-checkbox-group v-model="currentRow.competitionArr" @change="changeCompetition()">
|
|
|
|
|
|
<el-checkbox label="1" :checked="competitionChecked" @change="competitionChecked=!competitionChecked">化验赛</el-checkbox>
|
|
|
|
|
|
<el-checkbox label="2" :checked="competitionChecked" @change="competitionChecked=!competitionChecked">虚拟赛</el-checkbox>
|
|
|
|
|
|
</el-checkbox-group>
|
2024-10-14 18:33:48 +08:00
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="学校名称">
|
|
|
|
|
|
<el-input v-model="currentRow.schoolName"></el-input>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="院系名称">
|
|
|
|
|
|
<el-input v-model="currentRow.collegeName"></el-input>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="团队名称">
|
|
|
|
|
|
<el-input v-model="currentRow.teamName"></el-input>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="盲样邮寄地址">
|
|
|
|
|
|
<el-input v-model="currentRow.sampleAddress"></el-input>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="收件人">
|
|
|
|
|
|
<el-input v-model="currentRow.sampleConcat"></el-input>
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
<el-form-item label="联系电话">
|
|
|
|
|
|
<el-input v-model="currentRow.sampleNumber"></el-input>
|
|
|
|
|
|
</el-form-item>
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<el-form-item labe l="附件">
|
2025-05-24 14:22:40 +08:00
|
|
|
|
<FileUpload :file-type="['doc','zip', 'docx', 'pdf']" limit="1" v-model="currentRow.uploadFile"></FileUpload>
|
2024-10-14 18:33:48 +08:00
|
|
|
|
</el-form-item>
|
|
|
|
|
|
</el-form>
|
|
|
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
|
|
|
<el-button @click="editDialogVisible = false">取 消</el-button>
|
|
|
|
|
|
<el-button type="primary" @click="saveData">确 定</el-button>
|
|
|
|
|
|
</span>
|
|
|
|
|
|
</el-dialog>
|
2024-07-26 18:59:02 +08:00
|
|
|
|
|
2025-02-18 17:12:16 +08:00
|
|
|
|
<!-- 用户导入对话框 -->
|
|
|
|
|
|
<el-dialog :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
|
|
|
|
|
|
<el-upload
|
|
|
|
|
|
ref="upload"
|
|
|
|
|
|
:limit="1"
|
|
|
|
|
|
accept=".xlsx, .xls"
|
|
|
|
|
|
:headers="upload.headers"
|
|
|
|
|
|
:action="upload.url + '?updateSupport=' + upload.updateSupport"
|
|
|
|
|
|
:disabled="upload.isUploading"
|
|
|
|
|
|
:on-progress="handleFileUploadProgress"
|
|
|
|
|
|
:on-success="handleFileSuccess"
|
|
|
|
|
|
:auto-upload="false"
|
|
|
|
|
|
drag
|
|
|
|
|
|
>
|
|
|
|
|
|
<i class="el-icon-upload"></i>
|
|
|
|
|
|
<div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
|
|
|
|
|
|
<div class="el-upload__tip text-center" slot="tip">
|
|
|
|
|
|
<div class="el-upload__tip" slot="tip">
|
|
|
|
|
|
<el-checkbox v-model="upload.updateSupport"/>
|
|
|
|
|
|
是否更新已经存在的用户数据
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<span>仅允许导入xls、xlsx格式文件。</span>
|
|
|
|
|
|
<el-link type="primary" :underline="false" style="font-size:12px;vertical-align: baseline;"
|
|
|
|
|
|
@click="importTemplate"
|
|
|
|
|
|
>下载模板
|
|
|
|
|
|
</el-link>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</el-upload>
|
|
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
|
|
<el-button type="primary" @click="submitFileForm">确 定</el-button>
|
|
|
|
|
|
<el-button @click="upload.open = false">取 消</el-button>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
2024-10-14 18:33:48 +08:00
|
|
|
|
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
@pagination="getList"
|
|
|
|
|
|
/>
|
2024-10-14 18:33:48 +08:00
|
|
|
|
<!-- Existing pagination -->
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
2024-07-27 18:02:04 +08:00
|
|
|
|
import {
|
|
|
|
|
|
listHitRegistrationStudentInfo,
|
|
|
|
|
|
getHitRegistrationStudentInfo,
|
|
|
|
|
|
delHitRegistrationStudentInfo,
|
|
|
|
|
|
addHitRegistrationStudentInfo,
|
|
|
|
|
|
updateHitRegistrationStudentInfo,
|
2024-10-08 10:54:15 +08:00
|
|
|
|
listHitRegistrationStudentInfoExport,
|
2024-10-14 18:33:48 +08:00
|
|
|
|
getTeachInfoByIds,
|
|
|
|
|
|
adminUpdateTeamInformation
|
2025-02-18 17:12:16 +08:00
|
|
|
|
} from '@/api/hit/registrationStudentInfo'
|
2025-05-24 14:22:40 +08:00
|
|
|
|
import {selectBaseInfo, editStatus} from '@/api/cms/baseInfo'
|
|
|
|
|
|
import {getHitRegistrationTeachInfoByUserId, selectByUserId} from '@/api/hit/teacherInfo'
|
|
|
|
|
|
import {editRegUser} from '@/api/officialWebsite/registerStudent'
|
|
|
|
|
|
import {mapState} from 'vuex'
|
|
|
|
|
|
import {getToken} from '@/utils/auth'
|
2024-07-26 18:59:02 +08:00
|
|
|
|
|
|
|
|
|
|
export default {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
name: 'HitRegistrationStudentInfo',
|
2025-05-24 14:22:40 +08:00
|
|
|
|
dicts: ['sys_user_sex', 'competition_type', 'com_racetrack','com_region'],
|
2024-07-26 18:59:02 +08:00
|
|
|
|
data() {
|
|
|
|
|
|
return {
|
2024-08-02 16:40:13 +08:00
|
|
|
|
yearList: [],
|
2024-08-20 18:02:46 +08:00
|
|
|
|
baseUrl: process.env.VUE_APP_BASE_API,
|
2025-02-18 17:12:16 +08:00
|
|
|
|
registerStatus: '',
|
2024-09-11 13:49:59 +08:00
|
|
|
|
leaderTeachList: [],
|
|
|
|
|
|
guideTeachList: [],
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 遮罩层
|
|
|
|
|
|
loading: true,
|
2024-09-11 09:28:32 +08:00
|
|
|
|
//当前用户id
|
2024-09-11 13:49:59 +08:00
|
|
|
|
userId: '',
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 选中数组
|
|
|
|
|
|
ids: [],
|
|
|
|
|
|
// 非单个禁用
|
|
|
|
|
|
single: true,
|
|
|
|
|
|
// 非多个禁用
|
|
|
|
|
|
multiple: true,
|
|
|
|
|
|
// 显示搜索条件
|
|
|
|
|
|
showSearch: true,
|
2024-09-11 09:28:32 +08:00
|
|
|
|
//当前登录老师的类型
|
2024-09-11 13:49:59 +08:00
|
|
|
|
techerType: 0,
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 总条数
|
|
|
|
|
|
total: 0,
|
|
|
|
|
|
// 报名信息表格数据
|
|
|
|
|
|
HitRegistrationStudentInfoList: [],
|
2025-05-24 14:22:40 +08:00
|
|
|
|
showCompetition: false,
|
|
|
|
|
|
competitionChecked: false,
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 弹出层标题
|
2025-02-18 17:12:16 +08:00
|
|
|
|
title: '',
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 是否显示弹出层
|
|
|
|
|
|
open: false,
|
2024-09-11 13:49:59 +08:00
|
|
|
|
zdTeacherList: [],
|
|
|
|
|
|
//当前登录老师的报名信息
|
|
|
|
|
|
registrationInformation: {},
|
2024-10-14 18:33:48 +08:00
|
|
|
|
// 修改对话框是否显示
|
|
|
|
|
|
editDialogVisible: false,
|
2025-05-24 14:22:40 +08:00
|
|
|
|
currentRow: {
|
|
|
|
|
|
racetrackArr: [],
|
|
|
|
|
|
competitionArr: [],
|
|
|
|
|
|
},
|
2025-02-18 17:12:16 +08:00
|
|
|
|
upload: {
|
|
|
|
|
|
// 是否显示弹出层(用户导入)
|
|
|
|
|
|
open: false,
|
|
|
|
|
|
// 弹出层标题(用户导入)
|
|
|
|
|
|
title: '',
|
|
|
|
|
|
// 是否禁用上传
|
|
|
|
|
|
isUploading: false,
|
|
|
|
|
|
// 是否更新已经存在的用户数据
|
|
|
|
|
|
updateSupport: 0,
|
|
|
|
|
|
// 设置上传的请求头部
|
2025-05-24 14:22:40 +08:00
|
|
|
|
headers: {Authorization: 'Bearer ' + getToken()},
|
2025-02-18 17:12:16 +08:00
|
|
|
|
// 上传的地址
|
|
|
|
|
|
url: process.env.VUE_APP_BASE_API + '/system/hit_reg_info/importData'
|
|
|
|
|
|
},
|
2025-05-24 14:22:40 +08:00
|
|
|
|
importType: "student",
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 查询参数
|
|
|
|
|
|
queryParams: {
|
|
|
|
|
|
pageNum: 1,
|
|
|
|
|
|
pageSize: 10,
|
2025-02-11 17:56:19 +08:00
|
|
|
|
year: new Date().getFullYear().toString(),
|
2024-07-26 18:59:02 +08:00
|
|
|
|
competitionName: null,
|
|
|
|
|
|
stuName: null,
|
|
|
|
|
|
stuGender: null,
|
|
|
|
|
|
stuMajor: null,
|
|
|
|
|
|
stuNumber: null,
|
|
|
|
|
|
schoolName: null,
|
|
|
|
|
|
division: null,
|
|
|
|
|
|
teamName: null,
|
|
|
|
|
|
leaderIds: null,
|
|
|
|
|
|
guideIds: null,
|
2024-09-11 13:49:59 +08:00
|
|
|
|
teachName: null,
|
2024-08-02 16:40:13 +08:00
|
|
|
|
createTime: null
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
// 表单参数
|
|
|
|
|
|
form: {},
|
2025-05-24 14:22:40 +08:00
|
|
|
|
checked: false,
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 表单校验
|
|
|
|
|
|
rules: {
|
|
|
|
|
|
competitionId: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '大赛ID不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
stuName: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '学生姓名不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
stuGender: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '学生性别不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
stuMajor: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '学生专业不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
stuNumber: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '学生手机号不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
schoolName: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '学校及院系名称不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
division: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '所属赛区不能为空', trigger: 'blur'}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
],
|
|
|
|
|
|
delFlag: [
|
2025-05-24 14:22:40 +08:00
|
|
|
|
{required: true, message: '逻辑删除0未删除1真删除不能为空', trigger: 'blur'}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
]
|
2024-07-26 18:59:02 +08:00
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
}
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
created() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.getList()
|
2024-08-02 16:40:13 +08:00
|
|
|
|
selectBaseInfo().then(res => {
|
|
|
|
|
|
this.registerStatus = res.data.registerStatus
|
|
|
|
|
|
})
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.yearList = this.years()
|
2024-09-11 09:28:32 +08:00
|
|
|
|
// 获取当前登陆人的id
|
2024-09-11 13:49:59 +08:00
|
|
|
|
this.userId = this.$store.state.user.id
|
2025-02-11 17:56:19 +08:00
|
|
|
|
this.getTeachInfoByIds(this.userId)
|
2024-09-21 13:49:15 +08:00
|
|
|
|
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2024-07-26 18:59:02 +08:00
|
|
|
|
methods: {
|
|
|
|
|
|
/** 查询报名信息列表 */
|
|
|
|
|
|
getList() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.loading = true
|
2025-02-11 17:56:19 +08:00
|
|
|
|
this.queryParams.year = new Date(this.queryParams.year).getFullYear().toString()
|
2024-07-26 18:59:02 +08:00
|
|
|
|
listHitRegistrationStudentInfo(this.queryParams).then(response => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.HitRegistrationStudentInfoList = response.rows
|
2024-09-11 13:49:59 +08:00
|
|
|
|
//判断数组是否为空
|
|
|
|
|
|
if (this.HitRegistrationStudentInfoList.length == 0) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.loading = false
|
2024-09-12 17:28:52 +08:00
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
console.log('报名信息', this.HitRegistrationStudentInfoList)
|
2025-05-24 14:22:40 +08:00
|
|
|
|
this.HitRegistrationStudentInfoList.map(row => {
|
|
|
|
|
|
const values = Array.isArray(row.racetrack)
|
|
|
|
|
|
? row.racetrack
|
|
|
|
|
|
: String(row.racetrack || '').split(',');
|
|
|
|
|
|
|
|
|
|
|
|
row.racetrackLabel = values
|
|
|
|
|
|
.map(val => {
|
|
|
|
|
|
const match = this.dict.type.com_racetrack.find(item => item.value === val);
|
|
|
|
|
|
return match ? match.label : val;
|
|
|
|
|
|
})
|
|
|
|
|
|
.join(',');
|
|
|
|
|
|
|
|
|
|
|
|
return row;
|
|
|
|
|
|
});
|
2024-09-21 13:49:15 +08:00
|
|
|
|
//for循环this.HitRegistrationStudentInfoList
|
2025-02-11 17:56:19 +08:00
|
|
|
|
if (this.HitRegistrationStudentInfoList.length != 0) {
|
|
|
|
|
|
for (let i = 0; i < this.HitRegistrationStudentInfoList.length; i++) {
|
|
|
|
|
|
//判断当前登录用户是否为指导老师
|
|
|
|
|
|
this.HitRegistrationStudentInfoList[i].zdTeacherList = this.HitRegistrationStudentInfoList[i].zdTeacher.map(teacher => teacher.userId)
|
|
|
|
|
|
this.HitRegistrationStudentInfoList[i].registrationInformation = {}
|
|
|
|
|
|
//循环this.registrationInformation
|
|
|
|
|
|
if (this.registrationInformation) {
|
|
|
|
|
|
for (let j = 0; j < this.registrationInformation.length; j++) {
|
|
|
|
|
|
if (this.registrationInformation[j].regId == this.HitRegistrationStudentInfoList[i].id) {
|
|
|
|
|
|
this.HitRegistrationStudentInfoList[i].registrationInformation = this.registrationInformation[j]
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.HitRegistrationStudentInfoList[i].competitionName = ''
|
2025-02-11 17:56:19 +08:00
|
|
|
|
//判断this.HitRegistrationStudentInfoList[i].competition不为空
|
|
|
|
|
|
if (this.HitRegistrationStudentInfoList[i].competition != null) {
|
2024-09-25 14:28:15 +08:00
|
|
|
|
|
2025-02-11 17:56:19 +08:00
|
|
|
|
const arr = this.splitStringToArray(this.HitRegistrationStudentInfoList[i].competition)
|
|
|
|
|
|
const arr2 = []
|
|
|
|
|
|
// 循环arr
|
|
|
|
|
|
for (let k = 0; k < arr.length; k++) {
|
|
|
|
|
|
//判断当前登录用户是否是指导老师
|
2025-02-18 17:12:16 +08:00
|
|
|
|
if (arr[k] == '1') {
|
2025-02-11 17:56:19 +08:00
|
|
|
|
arr2.push('化验赛')
|
|
|
|
|
|
// this.HitRegistrationStudentInfoList[0].competitionName += "化验赛"
|
2025-02-18 17:12:16 +08:00
|
|
|
|
} else if (arr[k] == '2') {
|
2025-02-11 17:56:19 +08:00
|
|
|
|
arr2.push('虚拟赛')
|
|
|
|
|
|
// this.HitRegistrationStudentInfoList[0].competitionName += ",虚拟赛"
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.HitRegistrationStudentInfoList[i].competitionName = this.arrayToString(arr2)
|
2024-09-25 14:28:15 +08:00
|
|
|
|
}
|
2024-09-25 13:23:11 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
2024-09-21 13:49:15 +08:00
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.total = response.total
|
|
|
|
|
|
this.loading = false
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
2025-05-24 14:22:40 +08:00
|
|
|
|
changeUpdateTeamRacetrack() {
|
|
|
|
|
|
//将数组转换为字符串
|
|
|
|
|
|
this.currentRow.racetrack = this.arrayToString(this.currentRow.racetrackArr)
|
|
|
|
|
|
console.log('字符串', this.currentRow.racetrack)
|
|
|
|
|
|
console.log('数组', this.currentRow.racetrackArr)
|
|
|
|
|
|
// 判断赛道中是否包含1
|
|
|
|
|
|
if (this.currentRow.racetrackArr.includes('1')) {
|
|
|
|
|
|
this.showCompetition = true
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.showCompetition = false
|
|
|
|
|
|
this.currentRow.competition = ''
|
|
|
|
|
|
this.currentRow.competitionArr = []
|
|
|
|
|
|
}
|
|
|
|
|
|
console.log('competitionArr', this.currentRow.competitionArr)
|
|
|
|
|
|
},
|
|
|
|
|
|
changeCompetition() {
|
|
|
|
|
|
//将数组转换为字符串
|
|
|
|
|
|
this.currentRow.competition = this.arrayToString(this.currentRow.competitionArr)
|
|
|
|
|
|
console.log('字符串', this.currentRow.competition)
|
|
|
|
|
|
console.log('数组', this.currentRow.competitionArr)
|
|
|
|
|
|
},
|
2025-02-18 17:12:16 +08:00
|
|
|
|
/** 导入按钮操作 */
|
|
|
|
|
|
handleImport(e) {
|
|
|
|
|
|
this.upload.title = '用户导入'
|
|
|
|
|
|
this.upload.open = true
|
|
|
|
|
|
if (e === 'team') {
|
|
|
|
|
|
//团队
|
|
|
|
|
|
this.upload.url = process.env.VUE_APP_BASE_API + '/system/hit_reg_info/importTeamData'
|
|
|
|
|
|
this.importType = 'team'
|
|
|
|
|
|
} else if (e === 'student') {
|
|
|
|
|
|
//学生
|
|
|
|
|
|
this.upload.url = process.env.VUE_APP_BASE_API + '/system/hit_reg_info/importData'
|
|
|
|
|
|
this.importType = 'student'
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
// 提交上传文件
|
|
|
|
|
|
submitFileForm() {
|
|
|
|
|
|
this.$refs.upload.submit()
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
2024-09-11 09:28:32 +08:00
|
|
|
|
//查询当前老师的类型
|
2024-09-11 13:49:59 +08:00
|
|
|
|
getTeachInfoByIds(id) {
|
2024-09-11 09:28:32 +08:00
|
|
|
|
getHitRegistrationTeachInfoByUserId(id).then(res => {
|
2025-02-11 17:56:19 +08:00
|
|
|
|
if (res.data) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
console.log('当前老师类型', res.data.type)
|
2025-02-11 17:56:19 +08:00
|
|
|
|
this.techerType = res.data.type
|
|
|
|
|
|
}
|
|
|
|
|
|
}).catch(err => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
console.log('查询当前老师的类型失败', err)
|
2024-09-11 09:28:32 +08:00
|
|
|
|
})
|
2024-09-21 13:49:15 +08:00
|
|
|
|
this.fetchRegistrationInformation()
|
2024-09-11 09:28:32 +08:00
|
|
|
|
},
|
2024-09-25 13:23:11 +08:00
|
|
|
|
splitStringToArray(str) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
return str.split(',').map(item => item.trim())
|
|
|
|
|
|
},
|
|
|
|
|
|
/** 下载模板操作 */
|
|
|
|
|
|
importTemplate() {
|
|
|
|
|
|
let url = 'system/hit_reg_info/importTemplate'
|
|
|
|
|
|
let filename = '学生成绩模板_'
|
|
|
|
|
|
if (this.importType === 'student') {
|
|
|
|
|
|
url = 'system/hit_reg_info/importTemplate'
|
|
|
|
|
|
filename = '学生成绩模板_'
|
|
|
|
|
|
} else if (this.importType === 'team') {
|
|
|
|
|
|
url = 'system/hit_reg_info/importTeamTemplate'
|
|
|
|
|
|
filename = '团队成绩模板_'
|
|
|
|
|
|
}
|
|
|
|
|
|
this.download(url, {}, filename + new Date().getTime() + '.xlsx')
|
|
|
|
|
|
},
|
|
|
|
|
|
// 文件上传中处理
|
|
|
|
|
|
handleFileUploadProgress(event, file, fileList) {
|
|
|
|
|
|
this.upload.isUploading = true
|
|
|
|
|
|
},
|
|
|
|
|
|
// 文件上传成功处理
|
|
|
|
|
|
handleFileSuccess(response, file, fileList) {
|
|
|
|
|
|
this.upload.open = false
|
|
|
|
|
|
this.upload.isUploading = false
|
|
|
|
|
|
this.$refs.upload.clearFiles()
|
2025-05-24 14:22:40 +08:00
|
|
|
|
this.$alert('<div style=\'overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;\'>' + response.msg + '</div>', '导入结果', {dangerouslyUseHTMLString: true})
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.getList()
|
2024-09-25 13:23:11 +08:00
|
|
|
|
},
|
|
|
|
|
|
//将数组转为字符串
|
|
|
|
|
|
arrayToString(arr) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
return arr.join(',')
|
2024-09-25 13:23:11 +08:00
|
|
|
|
},
|
2024-09-11 13:49:59 +08:00
|
|
|
|
//指导老师同意
|
2025-02-18 17:12:16 +08:00
|
|
|
|
submitData(data, status) {
|
2024-09-21 13:49:15 +08:00
|
|
|
|
data.status = status
|
2024-09-20 23:51:33 +08:00
|
|
|
|
|
2025-02-18 17:12:16 +08:00
|
|
|
|
console.log('这是提交的信息', data)
|
|
|
|
|
|
editRegUser(data).then(res => {
|
|
|
|
|
|
this.$modal.msgSuccess('成功')
|
|
|
|
|
|
this.fetchRegistrationInformation()
|
2024-09-11 13:49:59 +08:00
|
|
|
|
})
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.getList()
|
2024-09-11 13:49:59 +08:00
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
//查询当前老师的报名信息
|
|
|
|
|
|
fetchRegistrationInformation() {
|
|
|
|
|
|
selectByUserId(this.userId).then(res => {
|
2025-02-11 17:56:19 +08:00
|
|
|
|
if (res.data) {
|
|
|
|
|
|
this.registrationInformation = res.data
|
2025-02-18 17:12:16 +08:00
|
|
|
|
console.log('这是获取的信息', this.registrationInformation)
|
2025-02-11 17:56:19 +08:00
|
|
|
|
}
|
2024-09-11 13:49:59 +08:00
|
|
|
|
})
|
|
|
|
|
|
},
|
2024-07-26 18:59:02 +08:00
|
|
|
|
// 取消按钮
|
|
|
|
|
|
cancel() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.open = false
|
|
|
|
|
|
this.reset()
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
// 表单重置
|
|
|
|
|
|
reset() {
|
|
|
|
|
|
this.form = {
|
|
|
|
|
|
id: null,
|
|
|
|
|
|
competitionId: null,
|
|
|
|
|
|
stuName: null,
|
|
|
|
|
|
stuGender: null,
|
|
|
|
|
|
stuMajor: null,
|
|
|
|
|
|
stuNumber: null,
|
|
|
|
|
|
schoolName: null,
|
|
|
|
|
|
division: null,
|
|
|
|
|
|
teamName: null,
|
|
|
|
|
|
leaderIds: null,
|
|
|
|
|
|
guideIds: null,
|
|
|
|
|
|
remark: null,
|
|
|
|
|
|
delFlag: null,
|
|
|
|
|
|
createBy: null,
|
|
|
|
|
|
updateTime: null,
|
2024-08-02 16:40:13 +08:00
|
|
|
|
updateBy: null,
|
|
|
|
|
|
createTime: null
|
2025-02-18 17:12:16 +08:00
|
|
|
|
}
|
|
|
|
|
|
this.resetForm('form')
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
/** 搜索按钮操作 */
|
|
|
|
|
|
handleQuery() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.queryParams.pageNum = 1
|
|
|
|
|
|
this.getList()
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
/** 重置按钮操作 */
|
|
|
|
|
|
resetQuery() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.resetForm('queryForm')
|
2024-08-02 16:40:13 +08:00
|
|
|
|
this.queryParams.createTime = null
|
2025-05-24 14:22:40 +08:00
|
|
|
|
this.queryParams.racetrack = null
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.handleQuery()
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
// 多选框选中数据
|
|
|
|
|
|
handleSelectionChange(selection) {
|
|
|
|
|
|
this.ids = selection.map(item => item.id)
|
2024-09-11 13:49:59 +08:00
|
|
|
|
this.single = selection.length !== 1
|
2024-07-26 18:59:02 +08:00
|
|
|
|
this.multiple = !selection.length
|
|
|
|
|
|
},
|
|
|
|
|
|
/** 新增按钮操作 */
|
|
|
|
|
|
handleAdd() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.reset()
|
|
|
|
|
|
this.open = true
|
|
|
|
|
|
this.title = '添加报名信息'
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
/** 修改按钮操作 */
|
|
|
|
|
|
handleUpdate(row) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.reset()
|
2024-07-26 18:59:02 +08:00
|
|
|
|
const id = row.id || this.ids
|
|
|
|
|
|
getHitRegistrationStudentInfo(id).then(response => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.form = response.data
|
|
|
|
|
|
this.open = true
|
|
|
|
|
|
this.title = '修改报名信息'
|
|
|
|
|
|
})
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
2024-09-11 13:49:59 +08:00
|
|
|
|
auditData(data, status) {
|
2024-08-20 18:02:46 +08:00
|
|
|
|
data.auditStatus = status
|
|
|
|
|
|
updateHitRegistrationStudentInfo(data).then(response => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$modal.msgSuccess('成功')
|
2024-08-20 18:02:46 +08:00
|
|
|
|
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.getList()
|
|
|
|
|
|
})
|
2024-08-20 18:02:46 +08:00
|
|
|
|
},
|
2024-07-26 18:59:02 +08:00
|
|
|
|
/** 提交按钮 */
|
|
|
|
|
|
submitForm() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$refs['form'].validate(valid => {
|
2024-07-26 18:59:02 +08:00
|
|
|
|
if (valid) {
|
|
|
|
|
|
if (this.form.id != null) {
|
|
|
|
|
|
updateHitRegistrationStudentInfo(this.form).then(response => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$modal.msgSuccess('修改成功')
|
|
|
|
|
|
this.open = false
|
|
|
|
|
|
this.getList()
|
|
|
|
|
|
})
|
2024-07-26 18:59:02 +08:00
|
|
|
|
} else {
|
|
|
|
|
|
addHitRegistrationStudentInfo(this.form).then(response => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$modal.msgSuccess('新增成功')
|
|
|
|
|
|
this.open = false
|
|
|
|
|
|
this.getList()
|
|
|
|
|
|
})
|
2024-07-26 18:59:02 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
})
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
/** 删除按钮操作 */
|
|
|
|
|
|
handleDelete(row) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
const ids = row.id || this.ids
|
2025-05-24 14:22:40 +08:00
|
|
|
|
this.$modal.confirm('是否确认删除报名信息编号为"' + ids + '"的数据项?').then(function () {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
return delHitRegistrationStudentInfo(ids)
|
2024-07-26 18:59:02 +08:00
|
|
|
|
}).then(() => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.getList()
|
|
|
|
|
|
this.$modal.msgSuccess('删除成功')
|
|
|
|
|
|
}).catch(() => {
|
|
|
|
|
|
})
|
2024-07-26 18:59:02 +08:00
|
|
|
|
},
|
|
|
|
|
|
/** 导出按钮操作 */
|
|
|
|
|
|
handleExport() {
|
2024-10-08 10:54:15 +08:00
|
|
|
|
this.download('system/hit_reg_info/export', {
|
2024-07-26 18:59:02 +08:00
|
|
|
|
...this.queryParams
|
|
|
|
|
|
}, `HitRegistrationStudentInfo_${new Date().getTime()}.xlsx`)
|
2024-07-27 18:02:04 +08:00
|
|
|
|
},
|
2024-09-11 13:49:59 +08:00
|
|
|
|
getTeachInfo(row) {
|
|
|
|
|
|
if (row.leaderIds !== null && row.leaderIds.length !== 0) {
|
2024-07-27 18:02:04 +08:00
|
|
|
|
getTeachInfoByIds(row.leaderIds).then(res => {
|
|
|
|
|
|
this.leaderTeachList = res.data
|
|
|
|
|
|
})
|
|
|
|
|
|
}
|
2024-09-11 13:49:59 +08:00
|
|
|
|
if (row.guideIds !== null && row.guideIds.length !== 0) {
|
2024-07-27 18:02:04 +08:00
|
|
|
|
getTeachInfoByIds(row.guideIds).then(res => {
|
|
|
|
|
|
this.guideTeachList = res.data
|
|
|
|
|
|
})
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
2024-09-11 13:49:59 +08:00
|
|
|
|
updateRegisterStatus() {
|
2024-08-02 16:40:13 +08:00
|
|
|
|
editStatus(this.registerStatus).then(res => {
|
2024-09-11 13:49:59 +08:00
|
|
|
|
if (res.code === 200) {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$modal.msgSuccess(this.registerStatus === '1' ? '报名已开启' : '报名已关闭')
|
2024-08-02 16:40:13 +08:00
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
years() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
const currentYear = new Date().getFullYear()
|
|
|
|
|
|
const startYear = currentYear - 40 // 假设从当前年份往前 20 年
|
|
|
|
|
|
const endYear = currentYear
|
|
|
|
|
|
const years = []
|
2024-08-02 16:40:13 +08:00
|
|
|
|
for (let year = startYear; year <= endYear; year++) {
|
|
|
|
|
|
years.push({
|
|
|
|
|
|
label: year,
|
2025-02-18 17:12:16 +08:00
|
|
|
|
value: year + '-01-01'
|
|
|
|
|
|
})
|
2024-08-02 16:40:13 +08:00
|
|
|
|
}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
return years.sort((a, b) => b.label - a.label)
|
2024-08-02 16:40:13 +08:00
|
|
|
|
},
|
2024-10-14 18:33:48 +08:00
|
|
|
|
editData(row) {
|
2025-05-24 14:22:40 +08:00
|
|
|
|
this.currentRow = {...row}
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.editDialogVisible = true
|
2025-05-24 14:22:40 +08:00
|
|
|
|
if (this.currentRow) {
|
|
|
|
|
|
//将字符串转为数组
|
|
|
|
|
|
if (this.currentRow.competition){
|
|
|
|
|
|
|
|
|
|
|
|
this.currentRow.competitionArr = this.currentRow.competition.split(',')
|
|
|
|
|
|
}else {
|
|
|
|
|
|
this.currentRow.competitionArr = []
|
|
|
|
|
|
}
|
|
|
|
|
|
console.log('这是数组', this.currentRow.competitionArr)
|
|
|
|
|
|
if (this.currentRow.racetrack) {
|
|
|
|
|
|
this.currentRow.racetrackArr = this.currentRow.racetrack.split(',')
|
|
|
|
|
|
if (this.currentRow.racetrackArr.includes('1')) {
|
|
|
|
|
|
this.showCompetition = true
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.showCompetition = false
|
|
|
|
|
|
this.currentRow.competitionArr = []
|
|
|
|
|
|
this.currentRow.competition = ''
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2024-10-14 18:33:48 +08:00
|
|
|
|
},
|
|
|
|
|
|
saveData() {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
console.log('保存数据', this.currentRow)
|
2024-10-14 18:33:48 +08:00
|
|
|
|
adminUpdateTeamInformation(this.currentRow).then(response => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$modal.msgSuccess('团队信息修改成功')
|
|
|
|
|
|
this.editDialogVisible = false
|
|
|
|
|
|
this.getList()
|
2024-10-14 18:33:48 +08:00
|
|
|
|
}).catch(error => {
|
2025-02-18 17:12:16 +08:00
|
|
|
|
this.$modal.msgError('团队信息修改失败')
|
|
|
|
|
|
})
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2025-02-18 17:12:16 +08:00
|
|
|
|
}
|
2024-10-14 18:33:48 +08:00
|
|
|
|
|
2024-07-26 18:59:02 +08:00
|
|
|
|
</script>
|
2024-07-27 18:02:04 +08:00
|
|
|
|
|
|
|
|
|
|
<style scoped lang="scss">
|
|
|
|
|
|
.demo-table-expand {
|
|
|
|
|
|
font-size: 0;
|
|
|
|
|
|
}
|
2024-09-11 13:49:59 +08:00
|
|
|
|
|
2024-07-27 18:02:04 +08:00
|
|
|
|
.demo-table-expand label {
|
|
|
|
|
|
width: 90px;
|
|
|
|
|
|
color: #99a9bf;
|
|
|
|
|
|
}
|
2024-09-11 13:49:59 +08:00
|
|
|
|
|
2024-07-27 18:02:04 +08:00
|
|
|
|
.demo-table-expand .el-form-item {
|
|
|
|
|
|
margin-right: 0;
|
|
|
|
|
|
margin-bottom: 0;
|
|
|
|
|
|
width: 50%;
|
|
|
|
|
|
}
|
|
|
|
|
|
</style>
|