赛事人员导入等

master
yujialong 8 months ago
parent 108c086f7a
commit 8d3cba7de7
  1. 1
      src/api/index.js
  2. BIN
      src/assets/img/entry.png
  3. 2
      src/layouts/header/index.vue
  4. 464
      src/pages/course/preview/index.vue
  5. 8
      src/pages/match/list/index.vue
  6. 157
      src/pages/match/manage/matchSignup.vue
  7. 3
      src/setting.js

@ -220,6 +220,7 @@ export default {
batchImportPersonalData: `${host}competition/competition/registration/batchImportPersonalData`, batchImportPersonalData: `${host}competition/competition/registration/batchImportPersonalData`,
batchImportTeamData: `${host}competition/competition/registration/batchImportTeamData`, batchImportTeamData: `${host}competition/competition/registration/batchImportTeamData`,
TeamDataExportFailure: `${host}competition/competition/registration/exportFailure`, TeamDataExportFailure: `${host}competition/competition/registration/exportFailure`,
batchDeleteApplicants: `competition/competition/registration/batchDeleteApplicants`,
competionPersonTemplate: `https://huoran.oss-cn-shenzhen.aliyuncs.com/%E6%95%99%E5%B8%88%E7%AB%AF%E4%B8%AA%E4%BA%BA%E8%B5%9B%E6%8A%A5%E5%90%8D%E4%BA%BA%E5%91%98%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx`, // 教师端个人报名人员模板 competionPersonTemplate: `https://huoran.oss-cn-shenzhen.aliyuncs.com/%E6%95%99%E5%B8%88%E7%AB%AF%E4%B8%AA%E4%BA%BA%E8%B5%9B%E6%8A%A5%E5%90%8D%E4%BA%BA%E5%91%98%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx`, // 教师端个人报名人员模板
competionTeamTemplate: `https://huoran.oss-cn-shenzhen.aliyuncs.com/%E6%95%99%E5%B8%88%E7%AB%AF%E5%9B%A2%E9%98%9F%E8%B5%9B%E6%8A%A5%E5%90%8D%E4%BA%BA%E5%91%98%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx`, // 教师端团队报名人员导入模板 competionTeamTemplate: `https://huoran.oss-cn-shenzhen.aliyuncs.com/%E6%95%99%E5%B8%88%E7%AB%AF%E5%9B%A2%E9%98%9F%E8%B5%9B%E6%8A%A5%E5%90%8D%E4%BA%BA%E5%91%98%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx`, // 教师端团队报名人员导入模板

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

@ -104,7 +104,7 @@ export default {
this.getSystemDetail(); this.getSystemDetail();
this.getUserDetail(); this.getUserDetail();
this.getNotice() this.getNotice()
this.heartbeatDetection() Setting.isPro && this.heartbeatDetection()
}, },
methods: { methods: {
...mapMutations("user", [ ...mapMutations("user", [

@ -1,6 +1,6 @@
<template> <template>
<!-- 课程预览 --> <!-- 课程预览 -->
<div> <div class="wrap">
<el-card shadow="hover" <el-card shadow="hover"
class="m-b-20"> class="m-b-20">
<div class="flex-between"> <div class="flex-between">
@ -9,102 +9,118 @@
</div> </div>
</el-card> </el-card>
<el-card shadow="hover" <div class="flex">
class="m-b-20" <div class="cover"
style="background: none;"> :class="{'is-word': showMask1}">
<div class="flex"> <img v-if="coverUrl"
<div class="cover" :src="coverUrl"
:class="{'is-word': showMask1}"> alt=""
<img v-if="coverUrl" width="100%"
:src="coverUrl" height="100%">
alt="" <template v-else-if="iframeSrc">
width="100%" <iframe class="inner fileIframe"
height="100%"> id="fileIframe"
<template v-else-if="iframeSrc"> :src="iframeSrc"
<iframe class="inner fileIframe" frameborder="0"></iframe>
id="fileIframe" <template v-if="showMask">
:src="iframeSrc" <div class="mask"
frameborder="0"></iframe> style="width: 500px;height: 30px;top: 53px;right: 320px"></div>
<template v-if="showMask"> <div class="mask"
<div class="mask" style="width: 175px;height: 30px;top: 53px;right: 5px"></div>
style="width: 500px;height: 30px;top: 53px;right: 320px"></div>
<div class="mask"
style="width: 175px;height: 30px;top: 53px;right: 5px"></div>
</template>
<template v-if="showMask1">
<div class="word-mask"
style="height: 40px;"></div>
<div class="word-mask2"
style="top: 55px;left: 28%;width: 44%;height: calc(100% - 80px);"></div>
</template>
<template v-if="showMask2">
<div class="excel-mask1"
style="height: 48px;"></div>
</template>
</template> </template>
<div class="pdf inner" <template v-if="showMask1">
v-else-if="pdfSrc"> <div class="word-mask"
<p class="arrow"> style="height: 40px;"></div>
<span @click="changePdfPage(0)" <div class="word-mask2"
class="turn el-icon-arrow-left" style="top: 55px;left: 28%;width: 44%;height: calc(100% - 80px);"></div>
:class="{grey: currentPage==1}"></span> </template>
{{ currentPage }} / {{ pageCount }} <template v-if="showMask2">
<span @click="changePdfPage(1)" <div class="excel-mask1"
class="turn el-icon-arrow-right" style="height: 48px;"></div>
:class="{grey: currentPage==pageCount}"></span> </template>
</p> </template>
<pdf class="pdf-wrap" <div class="pdf inner"
:src="pdfSrc" v-else-if="pdfSrc">
:page="currentPage" <p class="arrow">
@num-pages="pageCount=$event" <span @click="changePdfPage(0)"
@page-loaded="currentPage=$event" class="turn el-icon-arrow-left"
@loaded="loadPdfHandler"> :class="{grey: currentPage==1}"></span>
</pdf> {{ currentPage }} / {{ pageCount }}
</div> <span @click="changePdfPage(1)"
<div class="inner" class="turn el-icon-arrow-right"
v-else-if="playAuth"> :class="{grey: currentPage==pageCount}"></span>
<div class="video_wid" </p>
id="player"></div> <pdf class="pdf-wrap"
</div> :src="pdfSrc"
:page="currentPage"
@num-pages="pageCount=$event"
@page-loaded="currentPage=$event"
@loaded="loadPdfHandler">
</pdf>
</div> </div>
<div class="catalog flex-1"> <div class="inner"
<div class="list"> v-else-if="playAuth">
<h4 class="title">{{ courseName }}</h4> <div class="video_wid"
<div class="desc-wrap"> id="player"></div>
<div class="desc" </div>
:class="{active: desShrink}" </div>
v-html="description"></div> <div class="catalog flex-1">
<i class="arrow" <div class="list">
<h4 class="title">{{ courseName }}</h4>
<div class="desc-wrap">
<div class="desc"
:class="{active: desShrink}" :class="{active: desShrink}"
v-if="description.length > 40"> v-html="description"></div>
<span>...</span> <i class="arrow"
<img src="@/assets/img/arrow-down.png" :class="{active: desShrink}"
alt="" v-if="description.length > 40">
@click="desShrink = !desShrink"> <span>...</span>
</i> <img src="@/assets/img/arrow-down.png"
</div> alt=""
<div class="chapters"> @click="desShrink = !desShrink">
<template v-if="videoList.length"> </i>
<div class="chapter" </div>
v-for="(item,index) in videoList" <div class="chapters">
:key="index"> <template v-if="videoList.length">
<div class="chapterName">{{ item.name }}</div> <div class="chapter"
<div class="section" v-for="(item,index) in videoList"
v-if="item.subsectionList.length"> :key="index">
<div v-for="(section,i) in item.subsectionList" <div class="chapterName">{{ item.name }}</div>
:key="i" <div class="section"
@click="preview(section, item.name)"> v-if="item.subsectionList.length">
<p class="sectionName" <div v-for="(section,i) in item.subsectionList"
:class="{active: curLink === `${item.name}${section.name}`}">{{ section.name }}</p> :key="i"
</div> @click="preview(section, item.name)">
<p class="sectionName"
:class="{active: curLink === `${item.name}${section.name}`}">
<img v-if="section.fileType === 'pptx'"
src="@/assets/img/exts/ppt.png"
alt="">
<img v-else-if="section.fileType === 'mp4'"
src="@/assets/img/exts/video.png"
alt="">
<img v-else-if="section.fileType === 'doc' || section.fileType === 'docx'"
src="@/assets/img/exts/word.png"
alt="">
<img v-else-if="section.fileType === 'txt'"
src="@/assets/img/exts/txt.png"
alt="">
<img v-else-if="section.fileType === 'pdf'"
src="@/assets/img/exts/pdf.png"
alt="">
<img v-else
src="@/assets/img/exts/pic.png"
alt="">
{{ section.name }}
</p>
</div> </div>
</div> </div>
</template> </div>
</div> </template>
</div> </div>
</div> </div>
</div> </div>
</el-card> </div>
</div> </div>
</template> </template>
@ -285,30 +301,42 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.wrap {
padding: 0 200px;
}
$height: 700px; $height: 700px;
.video_wid, .video_wid,
.cover { .cover {
position: relative; position: relative;
width: 76%; width: 76%;
max-width: 1400px;
height: $height !important; height: $height !important;
border: 0; border: 0;
} }
.page {
/deep/.des {
overflow: auto;
div,
p,
span {
font-family: PingFangSC-Regular !important;
}
}
}
.l-title {
font-size: 17px;
}
.cover { .cover {
background-color: #252528;
img { img {
border-radius: 8px; border-radius: 8px;
} }
&.is-word { &.is-word {
overflow: hidden; overflow: hidden;
} }
} }
.fileIframe { .fileIframe {
height: $height !important; height: $height !important;
} }
.video_wid, .video_wid,
.inner { .inner {
width: 100%; width: 100%;
@ -316,49 +344,100 @@ $height: 700px;
border: 0; border: 0;
overflow: auto; overflow: auto;
} }
.cover.is-word { .cover.is-word {
.inner { .inner {
height: calc(100% + 38px) !important; height: calc(100% + 38px) !important;
margin-top: -38px; margin-top: -38px;
} }
} }
.video_wid:focus { .video_wid:focus {
outline: none; outline: none;
} }
.catalog { .catalog {
margin-left: 40px; width: 296px;
padding: 16px;
margin-left: 12px;
background-color: #252528;
.renew {
width: 100%;
margin-bottom: 16px;
font-size: 17px;
}
.entry {
display: block;
width: 100%;
height: 34px;
margin-bottom: 16px;
font-size: 17px;
color: #fff;
text-align: center;
line-height: 34px;
background: url(../../../assets/img/entry.png) 0 0/100% 100% no-repeat;
cursor: pointer;
&:hover {
opacity: 0.9;
}
}
.types {
display: flex;
margin: 15px 0;
.item {
display: inline-flex;
justify-content: center;
align-items: center;
width: 120px;
height: 40px;
color: #fff;
background-color: #4e4e4e;
border-radius: 4px;
cursor: pointer;
&:first-child {
margin-right: 10px;
}
&:hover {
background-color: #377be3;
}
&.active {
background-color: $main-color;
}
}
.icon {
margin-right: 5px;
font-size: 18px;
}
}
} }
.list { .list {
height: $height; height: calc(700px - 82px);
overflow-y: auto; overflow-y: auto;
padding: 24px 16px;
background: #fff;
.title { .title {
margin-bottom: 8px; margin-bottom: 11px;
color: rgba(0, 0, 0, 0.85); color: #fff;
font-size: 20px; font-size: 16px;
}
.pro-title {
margin-bottom: 5px;
color: #fff;
font-size: 12px;
}
/deep/.el-progress-bar {
width: 92%;
}
/deep/.el-progress__text {
color: #fff;
} }
.desc-wrap { .desc-wrap {
position: relative; position: relative;
.desc { .desc {
font-size: 14px; font-size: 12px;
color: rgba(0, 0, 0, 0.65); color: #fff;
line-height: 22px; line-height: 22px;
@include mul-ellipsis(2); @include mul-ellipsis(2);
&.active { &.active {
display: block; display: block;
overflow: visible; overflow: visible;
} }
} }
.arrow { .arrow {
position: absolute; position: absolute;
bottom: 2px; bottom: 2px;
@ -367,62 +446,79 @@ $height: 700px;
justify-content: space-between; justify-content: space-between;
width: 46px; width: 46px;
background-color: #fff; background-color: #fff;
span { span {
font-size: 14px; font-size: 14px;
color: rgba(0, 0, 0, 0.65); color: rgba(0, 0, 0, 0.65);
} }
img { img {
width: 16px; width: 16px;
cursor: pointer; cursor: pointer;
} }
&.active { &.active {
span { span {
opacity: 0; opacity: 0;
} }
img { img {
transform: rotate(180deg); transform: rotate(180deg);
} }
} }
} }
} }
.chapters { .chapters {
margin-top: 16px; margin-top: 16px;
max-height: calc(100% - 53px); max-height: calc(100% - 53px);
overflow: auto; overflow: auto;
} }
.chapter { .chapter {
margin-bottom: 20px; margin-bottom: 20px;
}
.chapterName { .chapterName {
color: rgba(0, 0, 0, 0.85); color: #fff;
font-size: 16px; font-size: 14px;
}
.section {
padding: 5px 15px;
margin-top: 12px;
background-color: #121214;
}
.sectionName {
position: relative;
padding-right: 15px;
margin: 12px 0;
font-size: 12px;
color: #999;
cursor: pointer;
@include ellipsis;
img {
margin-right: 8px;
} }
.icon {
.section { position: absolute;
padding: 5px 15px; right: 0;
margin-top: 8px; font-size: 14px;
background: rgba(0, 0, 0, 0.02); color: #00c935;
}
.sectionName { .circle {
margin: 10px 0; width: 14px;
font-size: 14px; height: 14px;
color: rgba(0, 0, 0, 0.65); border-radius: 50%;
cursor: pointer; border: 1px solid #ccc;
@include ellipsis; }
&.active { &.active {
color: #9278ff; color: #fff;
}
}
} }
} }
} }
.buy {
text-align: center;
.tips {
margin-bottom: 10px;
font-size: 14px;
}
img {
width: 85%;
}
}
.el-image-viewer__wrapper { .el-image-viewer__wrapper {
transform: translateY(-10px); transform: translateY(-10px);
transition: transform 0.5s; transition: transform 0.5s;
@ -431,23 +527,19 @@ $height: 700px;
transform: translateY(0); transform: translateY(0);
} }
} }
.el-image-viewer__close { .el-image-viewer__close {
z-index: 2000; z-index: 2000;
top: 15px; top: 15px;
right: 15px; right: 15px;
&.doc-close { &.doc-close {
i { i {
// color: #000 !important; color: #000 !important;
} }
} }
} }
.list::-webkit-scrollbar { .list::-webkit-scrollbar {
width: 4px; width: 4px;
} }
.list::-webkit-scrollbar-thumb { .list::-webkit-scrollbar-thumb {
border-radius: 10px; border-radius: 10px;
background: rgba(0, 0, 0, 0.06); background: rgba(0, 0, 0, 0.06);
@ -458,7 +550,6 @@ $height: 700px;
position: absolute; position: absolute;
background-color: rgb(57, 58, 61); background-color: rgb(57, 58, 61);
} }
.word-mask { .word-mask {
z-index: 9; z-index: 9;
position: absolute; position: absolute;
@ -467,7 +558,6 @@ $height: 700px;
width: 100%; width: 100%;
background-color: rgb(243, 242, 241); background-color: rgb(243, 242, 241);
} }
.word-mask1 { .word-mask1 {
z-index: 9; z-index: 9;
position: absolute; position: absolute;
@ -476,13 +566,11 @@ $height: 700px;
width: 100%; width: 100%;
background-color: #185abd; background-color: #185abd;
} }
.word-mask2 { .word-mask2 {
z-index: 9; z-index: 9;
position: absolute; position: absolute;
background-color: transparent; background-color: transparent;
} }
.excel-mask1 { .excel-mask1 {
z-index: 9; z-index: 9;
position: absolute; position: absolute;
@ -491,29 +579,30 @@ $height: 700px;
width: 60%; width: 60%;
background-color: #107c41; background-color: #107c41;
} }
/deep/.pdf-dia {
/deep/ .pdf-dia {
border-radius: 0 !important; border-radius: 0 !important;
.el-dialog__header { .el-dialog__header {
display: none; display: none;
} }
.el-dialog__body { .el-dialog__body {
padding: 0; padding: 0;
} }
.el-dialog__headerbtn { .el-dialog__headerbtn {
top: 10px; top: 10px;
.el-dialog__close { .el-dialog__close {
color: #fff; color: #fff;
font-size: 16px; font-size: 16px;
} }
} }
} }
.pdf { .pdf {
position: relative;
.full {
position: absolute;
top: 7px;
right: 10px;
cursor: pointer;
}
.arrow { .arrow {
padding: 10px 0; padding: 10px 0;
display: flex; display: flex;
@ -522,17 +611,78 @@ $height: 700px;
font-size: 16px; font-size: 16px;
color: #fff; color: #fff;
background-color: #333; background-color: #333;
.turn { .turn {
margin: 0 10px; margin: 0 10px;
font-size: 18px; font-size: 18px;
cursor: pointer; cursor: pointer;
} }
} }
.pdf-wrap { .pdf-wrap {
width: 80%; width: 80%;
margin: 0 auto; margin: 0 auto;
} }
} }
/deep/.project-dia {
.el-dialog__body {
padding: 28px 32px;
}
}
.projects {
display: flex;
flex-wrap: wrap;
max-height: 400px;
overflow: auto;
li {
display: inline-flex;
align-items: center;
width: 238px;
padding: 16px;
margin: 0 20px 20px 0;
background-color: #f6f8fa;
border-radius: 16px;
cursor: pointer;
&:hover {
span {
color: #007eff;
}
}
&:nth-child(3n) {
margin-right: 0;
}
&.active {
background-color: #f2f7ff;
span {
color: #3988ff;
}
}
}
span {
max-width: 140px;
margin-left: 14px;
font-size: 14px;
color: #333;
}
}
.tabs {
display: flex;
align-items: center;
margin: 10px 0;
.item {
padding: 0 10px;
margin-right: 16px;
font-size: 16px;
text-align: center;
color: #333;
line-height: 50px;
border-bottom: 3px solid transparent;
cursor: pointer;
&.active {
color: #007eff;
border-color: #007eff;
}
}
}
.tab-content {
width: calc(100% - 308px);
}
</style> </style>

@ -91,6 +91,14 @@
<el-table-column prop="competitionName" <el-table-column prop="competitionName"
label="竞赛名称" label="竞赛名称"
align="center"></el-table-column> align="center"></el-table-column>
<el-table-column prop="name"
label="竞赛类型"
width="90"
align="center">
<template slot-scope="scope">
{{ scope.row.setup ? (scope.row.setup.competitionType ? '团队赛' : '个人赛') : '' }}
</template>
</el-table-column>
<el-table-column prop="applicantNum" <el-table-column prop="applicantNum"
label="报名人数" label="报名人数"
align="center" align="center"

@ -6,12 +6,12 @@
<ul class="filter"> <ul class="filter">
<li> <li>
<label>搜索</label> <label>搜索</label>
<el-input placeholder="请输入姓名/手机号/学号" <el-input :placeholder="'请输入姓名、手机号、' + (info.completeCompetitionSetup.competitionType ? '团队名称、' : '') + '学号、学校'"
prefix-icon="el-icon-search" prefix-icon="el-icon-search"
v-model="keyword" v-model="keyword"
clearable clearable
size="mini" size="mini"
style="width: 250px"></el-input> style="width: 350px"></el-input>
</li> </li>
<li v-if="info.releaseType"> <li v-if="info.releaseType">
<label>参赛人员状态</label> <label>参赛人员状态</label>
@ -25,6 +25,9 @@
</li> </li>
</ul> </ul>
<div> <div>
<el-button type="primary"
round
@click="autoAllocation">自动分配阶段成员</el-button>
<el-button type="primary" <el-button type="primary"
round round
@click="batchImport">导入</el-button> @click="batchImport">导入</el-button>
@ -36,6 +39,10 @@
round round
@click="exportAll" @click="exportAll"
v-auth="'/match/list:管理:报名人员:批量导出'">批量导出</el-button> v-auth="'/match/list:管理:报名人员:批量导出'">批量导出</el-button>
<el-button type="primary"
@click="batchDel"
round
v-auth="'/match:管理:报名人员:导出'">批量删除</el-button>
</div> </div>
</div> </div>
@ -60,31 +67,75 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="school" <el-table-column prop="school"
label="学校" label="学生账号归属"
sortable="custom"> min-width="180"
align="center">
</el-table-column>
<el-table-column prop="realSchool"
label="学生所属院校"
sortable="custom"
min-width="180"
align="center">
</el-table-column> </el-table-column>
<el-table-column v-if="info.completeCompetitionSetup.competitionType" <el-table-column v-if="info.completeCompetitionSetup.competitionType"
prop="teamName" prop="teamName"
label="团队名称" label="团队名称"
sortable="custom"> sortable="custom"
min-width="140"
align="center">
</el-table-column> </el-table-column>
<el-table-column prop="username" <el-table-column prop="username"
label="学生姓名"> label="队长/成员"
min-width="140"
align="center">
</el-table-column> </el-table-column>
<el-table-column prop="workNumber" <el-table-column prop="workNumber"
label="学号"> label="队长/成员学号"
min-width="140"
align="center">
</el-table-column> </el-table-column>
<el-table-column prop="phone" <el-table-column prop="phone"
label="手机号"> label="队长/成员手机号"
min-width="140"
align="center">
</el-table-column>
<el-table-column label="是否为队长"
min-width="80"
align="center">
<template slot-scope="scope">
{{ scope.row.captain ? '否' : '是' }}
</template>
</el-table-column>
<el-table-column prop="teachers"
label="指导老师"
min-width="200"
align="center"
show-overflow-tooltip>
<template slot-scope="scope">
<template v-if="scope.row.teachers">
<el-tooltip placement="top">
<div slot="content"
style="line-height: 1.8">
<div v-for="(item, i) in scope.row.teachers"
:key="i">
{{ item.name }}{{ item.phone ? ',' + item.phone : '' }}{{ item.position ? ',' + item.position : '' }}
</div>
</div>
<p>{{ scope.row.teachers[0].name }}{{ scope.row.teachers[0].phone ? ',' + scope.row.teachers[0].phone : '' }}{{ scope.row.teachers[0].position ? ',' + scope.row.teachers[0].position : '' }}</p>
</el-tooltip>
</template>
</template>
</el-table-column> </el-table-column>
<el-table-column label="操作" <el-table-column label="操作"
align="center" align="center"
width="320"> width="270">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button v-if="scope.row.identification" <el-button v-if="scope.row.identification"
type="text" type="text"
@click="edit(scope.row)" @click="edit(scope.row)"
v-auth="'/match/list:管理:报名人员:编辑'">编辑</el-button> v-auth="'/match/list:管理:报名人员:编辑'">编辑</el-button>
<el-button type="text"
@click="del(scope.row)">删除</el-button>
<template v-if="info.releaseType"> <template v-if="info.releaseType">
<el-button type="text" <el-button type="text"
@click="toInfo(scope.row)" @click="toInfo(scope.row)"
@ -118,12 +169,25 @@
<el-form ref="form" <el-form ref="form"
:model="form" :model="form"
:rules="rules" :rules="rules"
label-width="80px" label-width="110px"
style='margin-right: 10px;'> style='margin-right: 10px;'>
<el-form-item v-if="!schoolDisable" <el-form-item v-if="!schoolDisable"
prop="schoolId" prop="schoolId"
label="院校"> label="学生账号归属">
<el-select v-model="form.schoolId" <el-select v-model="form.schoolId"
filterable
:disabled="!isAdd"
style="width: 100%">
<el-option v-for="(item, i) in clients"
:key="i"
:label="item.schoolName"
:value="item.schoolId"></el-option>
</el-select>
</el-form-item>
<el-form-item v-if="!schoolDisable"
prop="studentAffiliatedInstitutionId"
label="学生所属院校">
<el-select v-model="form.studentAffiliatedInstitutionId"
filterable filterable
style="width: 100%"> style="width: 100%">
<el-option v-for="(item, i) in clients" <el-option v-for="(item, i) in clients"
@ -303,6 +367,7 @@ export default {
userName: '', userName: '',
workNumber: '', workNumber: '',
schoolId: '', schoolId: '',
studentAffiliatedInstitutionId: '',
teamId: '', teamId: '',
whetherSignUp: 0, whetherSignUp: 0,
phone: '', phone: '',
@ -359,12 +424,16 @@ export default {
} }
}, },
mounted () { mounted () {
console.log(44, this.$store.state.user.schoolId)
this.initData() this.initData()
this.getInfo() this.getInfo()
this.getTeam() this.getTeam()
}, },
methods: { methods: {
init () {
this.initData()
this.getTeam()
this.getClient()
},
getData () { getData () {
this.$post(this.api.queryRegistrationByCondition, { this.$post(this.api.queryRegistrationByCondition, {
pageNum: this.page, pageNum: this.page,
@ -375,7 +444,13 @@ export default {
schoolOrder: this.schoolOrder, schoolOrder: this.schoolOrder,
teamOrder: this.teamOrder, teamOrder: this.teamOrder,
}).then(({ data }) => { }).then(({ data }) => {
this.listData = data.records; const list = data.records;
list.map(e => {
if (e.teacherDetails) {
e.teachers = JSON.parse(e.teacherDetails)
}
})
this.listData = list
this.total = data.total; this.total = data.total;
this.$refs.table.clearSelection(); this.$refs.table.clearSelection();
}).catch(res => { }).catch(res => {
@ -415,6 +490,10 @@ export default {
if (column.prop === 'teamName') this.teamOrder = column.order ? column.order === 'ascending' ? 2 : 1 : '' if (column.prop === 'teamName') this.teamOrder = column.order ? column.order === 'ascending' ? 2 : 1 : ''
this.getData() this.getData()
}, },
//
autoAllocation () {
},
// //
@ -440,7 +519,8 @@ export default {
responseType: 'blob' responseType: 'blob'
}).then((res) => { }).then((res) => {
console.log("🚀 ~ showFaild ~ res:", res) console.log("🚀 ~ showFaild ~ res:", res)
util.downloadFileDirect(decodeURI(res.headers['content-disposition']), new Blob([res.data])) const name = res.headers['content-disposition']
util.downloadFileDirect(name ? decodeURI(name) : '批量导入报名人员失败数据导出.xlsx', new Blob([res.data]))
}).catch(res => { }) }).catch(res => { })
}, },
uploadSuccess ({ data, status }) { uploadSuccess ({ data, status }) {
@ -470,6 +550,7 @@ export default {
this.uploadFaild = false this.uploadFaild = false
}, },
uploadSure () { uploadSure () {
this.init()
this.importVisible = false this.importVisible = false
this.keyWord = '' this.keyWord = ''
}, },
@ -490,13 +571,30 @@ export default {
this.originForm = JSON.parse(JSON.stringify(row)) this.originForm = JSON.parse(JSON.stringify(row))
this.form = JSON.parse(JSON.stringify(row)) this.form = JSON.parse(JSON.stringify(row))
}, },
del (row) {
this.$confirm(row.captain ? '此删除操作不可逆,是否确认删除选中项?' : '删除队长后,该团队下所有成员都会同步移除报名,是否确认删除?', "提示", {
type: "warning"
})
.then(() => {
this.$post(this.api.batchDeleteApplicants, { registrationVOS: [row] }).then(res => {
util.successMsg("删除成功");
this.getData();
}).catch(res => {
});
})
.catch(() => {
});
},
// //
workNumberChange () { workNumberChange () {
const { form } = this const { form } = this
if (this.originForm.workNumber !== form.workNumber) { if (this.originForm.workNumber !== form.workNumber) {
form.schoolId && form.workNumber && this.$get(`${this.api.enquireAboutSchoolStudents}?schoolId=${form.schoolId}&workNumber=${form.workNumber}${this.isAdd ? '' : '&applyFor=1'}`).then(({ account }) => { form.schoolId && form.workNumber && this.$get(`${this.api.enquireAboutSchoolStudents}?schoolId=${form.schoolId}&workNumber=${form.workNumber}${this.isAdd ? '' : '&applyFor=1'}`).then(({ account }) => {
this.notExit = 0
this.exitMember = 0 this.exitMember = 0
if (account) { if (account) {
const { studentAffiliatedInstitutionId } = form
account.studentAffiliatedInstitutionId = studentAffiliatedInstitutionId
this.form = account this.form = account
} }
this.formEnable = !account this.formEnable = !account
@ -534,6 +632,7 @@ export default {
// //
if (this.originForm.teamId !== form.teamId) { if (this.originForm.teamId !== form.teamId) {
this.$post(this.api.joinCompetitionTeam, { this.$post(this.api.joinCompetitionTeam, {
studentAffiliatedInstitutionId: form.studentAffiliatedInstitutionId,
accountId: form.id, accountId: form.id,
competitionId: this.id, competitionId: this.id,
teamId: form.teamId, teamId: form.teamId,
@ -541,7 +640,7 @@ export default {
whetherSignUp: 1 whetherSignUp: 1
}).then(res => { }).then(res => {
this.addVisible = false this.addVisible = false
this.getData() this.init()
this.submiting = false this.submiting = false
util.successMsg('编辑成功!') util.successMsg('编辑成功!')
}).catch(res => { }).catch(res => {
@ -549,7 +648,7 @@ export default {
}) })
} else { } else {
this.addVisible = false this.addVisible = false
this.getData() this.init()
this.submiting = false this.submiting = false
util.successMsg('编辑成功!') util.successMsg('编辑成功!')
} }
@ -559,6 +658,7 @@ export default {
} else { } else {
// //
this.$post(this.api[this.info.completeCompetitionSetup.competitionType ? 'joinCompetitionTeam' : 'addCompetitionRegistration'], { this.$post(this.api[this.info.completeCompetitionSetup.competitionType ? 'joinCompetitionTeam' : 'addCompetitionRegistration'], {
studentAffiliatedInstitutionId: form.studentAffiliatedInstitutionId,
accountId: form.id, accountId: form.id,
competitionId: this.id, competitionId: this.id,
teamId: this.form.teamId, teamId: this.form.teamId,
@ -566,7 +666,7 @@ export default {
whetherSignUp: 1 whetherSignUp: 1
}).then(res => { }).then(res => {
this.addVisible = false this.addVisible = false
this.getData() this.init()
this.submiting = false this.submiting = false
util.successMsg('报名成功!') util.successMsg('报名成功!')
}).catch(res => { }).catch(res => {
@ -650,10 +750,11 @@ export default {
if (!form.teamName) return util.errorMsg('请输入团队名称') if (!form.teamName) return util.errorMsg('请输入团队名称')
if (form.invitationCode.length !== 6) return util.errorMsg('请输入6位数团队邀请码') if (form.invitationCode.length !== 6) return util.errorMsg('请输入6位数团队邀请码')
form.accountId = this.form.id form.accountId = this.form.id
form.studentAffiliatedInstitutionId = this.form.studentAffiliatedInstitutionId
this.$post(this.api.addCompetitionTeam, form).then(res => { this.$post(this.api.addCompetitionTeam, form).then(res => {
this.teamVisible = false this.teamVisible = false
this.addVisible = false this.addVisible = false
this.getData() this.init()
util.successMsg('报名成功!') util.successMsg('报名成功!')
}).catch(res => { }) }).catch(res => { })
}, },
@ -683,7 +784,25 @@ export default {
util.downloadFileDirect(`报名人员.xls`, new Blob([res.data])) util.downloadFileDirect(`报名人员.xls`, new Blob([res.data]))
}).catch(res => { }) }).catch(res => { })
} }
} },
//
batchDel () {
if (this.multipleSelection.length) {
this.$confirm("确定要删除吗?", "提示", {
type: "warning"
}).then(() => {
this.$post(this.api.batchDeleteApplicants, { registrationVOS: this.multipleSelection }).then(res => {
this.getData();
this.$message.success("删除成功");
this.$refs.table.clearSelection()
}).catch(err => {
});
}).catch(() => {
});
} else {
this.$message.warning("请先选择数据 !");
}
},
} }
}; };
</script> </script>

@ -5,8 +5,7 @@ const url = location.host;
const isDev = process.env.NODE_ENV === "development"; // 开发环境 const isDev = process.env.NODE_ENV === "development"; // 开发环境
const isHh = url.includes("10.196.131.73"); //河海版本 const isHh = url.includes("10.196.131.73"); //河海版本
const isCH = url.includes("124.71.12.62"); //巢湖版本 const isCH = url.includes("124.71.12.62"); //巢湖版本
const isPro = url.includes("occupationlab.com"); //职站生产 const isPro = url.includes("occupationlab.com") || url.includes("izhixinyun.com"); //生产
const isZxy = url.includes("izhixinyun.com"); //智信云
const isTest = url.includes('121.37.12.51'); //中台测试服 const isTest = url.includes('121.37.12.51'); //中台测试服
const isSq = url.includes('10.20.100.204'); // 商丘 const isSq = url.includes('10.20.100.204'); // 商丘

Loading…
Cancel
Save