|
|
@ -30,11 +30,7 @@ |
|
|
|
@click="autoAllocation">自动分配阶段成员</el-button> |
|
|
|
@click="autoAllocation">自动分配阶段成员</el-button> |
|
|
|
<el-button type="primary" |
|
|
|
<el-button type="primary" |
|
|
|
round |
|
|
|
round |
|
|
|
@click="batchImport"> |
|
|
|
@click="batchImport">导入</el-button> |
|
|
|
<i v-if="uploading" |
|
|
|
|
|
|
|
class="el-icon-loading"></i> |
|
|
|
|
|
|
|
{{ uploading ? '正在' : '' }}导入 |
|
|
|
|
|
|
|
</el-button> |
|
|
|
|
|
|
|
<el-button type="primary" |
|
|
|
<el-button type="primary" |
|
|
|
round |
|
|
|
round |
|
|
|
@click="add" |
|
|
|
@click="add" |
|
|
@ -75,11 +71,21 @@ |
|
|
|
sortable="custom" |
|
|
|
sortable="custom" |
|
|
|
min-width="180" |
|
|
|
min-width="180" |
|
|
|
align="center"> |
|
|
|
align="center"> |
|
|
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
{{ scope.row.school }} |
|
|
|
|
|
|
|
<span v-if="scope.row.schoolStatus" |
|
|
|
|
|
|
|
style="color: #f00">(已删除)</span> |
|
|
|
|
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="realSchool" |
|
|
|
<el-table-column prop="realSchool" |
|
|
|
label="学生所属院校" |
|
|
|
label="学生所属院校" |
|
|
|
min-width="180" |
|
|
|
min-width="180" |
|
|
|
align="center"> |
|
|
|
align="center"> |
|
|
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
|
|
{{ scope.row.realSchool }} |
|
|
|
|
|
|
|
<span v-if="scope.row.realSchoolStatus" |
|
|
|
|
|
|
|
style="color: #f00">(已删除)</span> |
|
|
|
|
|
|
|
</template> |
|
|
|
</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" |
|
|
@ -317,6 +323,8 @@ |
|
|
|
<el-button type="primary" |
|
|
|
<el-button type="primary" |
|
|
|
:loading="uploading" |
|
|
|
:loading="uploading" |
|
|
|
class="ml20">上传文件<i class="el-icon-upload2 el-icon--right"></i></el-button> |
|
|
|
class="ml20">上传文件<i class="el-icon-upload2 el-icon--right"></i></el-button> |
|
|
|
|
|
|
|
<div slot="tip" |
|
|
|
|
|
|
|
class="el-upload__tip">建议文件数据在5000条以内,导入5000名学生大致需要10分钟</div> |
|
|
|
</el-upload> |
|
|
|
</el-upload> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
<template v-else> |
|
|
|
<template v-else> |
|
|
@ -324,16 +332,12 @@ |
|
|
|
<p type="primary" |
|
|
|
<p type="primary" |
|
|
|
style="margin-bottom: 10px;font-size: 14px;color: #9076FF;text-decoration: underline;cursor: pointer;" |
|
|
|
style="margin-bottom: 10px;font-size: 14px;color: #9076FF;text-decoration: underline;cursor: pointer;" |
|
|
|
@click="showFaild">部分数据导入失败,查看失败原因</p> |
|
|
|
@click="showFaild">部分数据导入失败,查看失败原因</p> |
|
|
|
<el-button type="primary" |
|
|
|
|
|
|
|
@click="uploadFaild = false">重新上传</el-button> |
|
|
|
|
|
|
|
</template> |
|
|
|
</template> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<span v-if="uploading" |
|
|
|
<span v-if="uploading" |
|
|
|
slot="footer" |
|
|
|
slot="footer" |
|
|
|
class="dialog-footer"> |
|
|
|
class="dialog-footer"> |
|
|
|
<el-button @click="cancelUpload">取消上传</el-button> |
|
|
|
<el-button @click="cancelUpload">停止导入</el-button> |
|
|
|
<el-button type="primary" |
|
|
|
|
|
|
|
@click="backstageUpload">后台上传</el-button> |
|
|
|
|
|
|
|
</span> |
|
|
|
</span> |
|
|
|
</el-dialog> |
|
|
|
</el-dialog> |
|
|
|
</div> |
|
|
|
</div> |
|
|
@ -517,8 +521,9 @@ export default { |
|
|
|
|
|
|
|
|
|
|
|
// 批量导入 |
|
|
|
// 批量导入 |
|
|
|
batchImport () { |
|
|
|
batchImport () { |
|
|
|
this.isBackstage = 0 |
|
|
|
|
|
|
|
this.importVisible = true |
|
|
|
this.importVisible = true |
|
|
|
|
|
|
|
this.uploadList = [] |
|
|
|
|
|
|
|
this.uploadFaild = false |
|
|
|
}, |
|
|
|
}, |
|
|
|
// 模板下载 |
|
|
|
// 模板下载 |
|
|
|
download () { |
|
|
|
download () { |
|
|
@ -546,12 +551,13 @@ export default { |
|
|
|
this.uploadTips = '' |
|
|
|
this.uploadTips = '' |
|
|
|
if (status === 200) { |
|
|
|
if (status === 200) { |
|
|
|
this.init() |
|
|
|
this.init() |
|
|
|
|
|
|
|
const { tip } = data |
|
|
|
if (data.exportCode) { |
|
|
|
if (data.exportCode) { |
|
|
|
this.exportCode = data.exportCode |
|
|
|
this.exportCode = data.exportCode |
|
|
|
this.uploadFaild = true |
|
|
|
this.uploadFaild = true |
|
|
|
this.uploadTips = data.tip |
|
|
|
this.uploadTips = tip |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
util.successMsg(data.tip, 3000) |
|
|
|
util[tip.includes('5000') ? 'errorMsg' : 'successMsg'](tip, 3000) |
|
|
|
this.importVisible = false |
|
|
|
this.importVisible = false |
|
|
|
this.keyWord = '' |
|
|
|
this.keyWord = '' |
|
|
|
} |
|
|
|
} |
|
|
@ -560,7 +566,6 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
uploadError (err, file, fileList) { |
|
|
|
uploadError (err, file, fileList) { |
|
|
|
console.log("🚀 ~ uploadError ~ err:", err) |
|
|
|
|
|
|
|
this.uploading = false |
|
|
|
this.uploading = false |
|
|
|
this.$message({ |
|
|
|
this.$message({ |
|
|
|
message: "上传出错,请重试!", |
|
|
|
message: "上传出错,请重试!", |
|
|
@ -579,14 +584,11 @@ export default { |
|
|
|
this.uploadFaild = false |
|
|
|
this.uploadFaild = false |
|
|
|
}, |
|
|
|
}, |
|
|
|
cancelUpload () { |
|
|
|
cancelUpload () { |
|
|
|
if (!this.isBackstage) { |
|
|
|
|
|
|
|
this.uploadList = [] |
|
|
|
|
|
|
|
this.$refs.upload.abort() |
|
|
|
|
|
|
|
this.uploading = false |
|
|
|
this.uploading = false |
|
|
|
|
|
|
|
this.$refs.upload.abort() |
|
|
|
|
|
|
|
this.keyWord = '' |
|
|
|
this.init() |
|
|
|
this.init() |
|
|
|
this.importVisible = false |
|
|
|
this.importVisible = false |
|
|
|
this.keyWord = '' |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
// 后台上传 |
|
|
|
// 后台上传 |
|
|
|
backstageUpload () { |
|
|
|
backstageUpload () { |
|
|
@ -661,6 +663,7 @@ export default { |
|
|
|
hrUserAccount: { |
|
|
|
hrUserAccount: { |
|
|
|
...form, |
|
|
|
...form, |
|
|
|
id: form.id, |
|
|
|
id: form.id, |
|
|
|
|
|
|
|
lastTimeInstitutionId: this.originForm.studentAffiliatedInstitutionId |
|
|
|
}, |
|
|
|
}, |
|
|
|
hrUserInfo: { |
|
|
|
hrUserInfo: { |
|
|
|
userId: form.userId, |
|
|
|
userId: form.userId, |
|
|
|