|
|
|
@ -85,17 +85,17 @@ |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="username" |
|
|
|
|
label="队长/成员" |
|
|
|
|
:label="info.completeCompetitionSetup.competitionType ? '队长/成员' : '学生姓名'" |
|
|
|
|
min-width="140" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="workNumber" |
|
|
|
|
label="队长/成员学号" |
|
|
|
|
:label="info.completeCompetitionSetup.competitionType ? '队长/成员学号' : '学号'" |
|
|
|
|
min-width="140" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="phone" |
|
|
|
|
label="队长/成员手机号" |
|
|
|
|
:label="info.completeCompetitionSetup.competitionType ? '队长/成员手机号' : '手机号'" |
|
|
|
|
min-width="140" |
|
|
|
|
align="center"> |
|
|
|
|
</el-table-column> |
|
|
|
@ -286,7 +286,7 @@ |
|
|
|
|
<el-button type="primary" |
|
|
|
|
@click="download">模板下载<i class="el-icon-download el-icon--right"></i></el-button> |
|
|
|
|
</div> |
|
|
|
|
<el-upload ref="importStaff" |
|
|
|
|
<el-upload ref="upload" |
|
|
|
|
name="file" |
|
|
|
|
accept=".xls,.xlsx" |
|
|
|
|
:on-remove="handleRemove" |
|
|
|
@ -298,6 +298,7 @@ |
|
|
|
|
competitionId: id, |
|
|
|
|
platformId: 1 |
|
|
|
|
}" |
|
|
|
|
:auto-upload="false" |
|
|
|
|
:on-exceed="handleExceed" |
|
|
|
|
:action="info.completeCompetitionSetup.competitionType ? this.api.batchImportTeamData : this.api.batchImportPersonalData" |
|
|
|
|
:file-list="uploadList" |
|
|
|
@ -529,10 +530,14 @@ export default { |
|
|
|
|
if (data.exportCode) { |
|
|
|
|
this.exportCode = data.exportCode |
|
|
|
|
this.uploadFaild = true |
|
|
|
|
util.errorMsg(data.tip) |
|
|
|
|
util.errorMsg(data.tip, 3000) |
|
|
|
|
} else { |
|
|
|
|
this.init() |
|
|
|
|
this.importVisible = false |
|
|
|
|
this.keyWord = '' |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
res.message ? util.errorMsg(res.message) : util.errorMsg("上传失败,请检查数据") |
|
|
|
|
util.errorMsg(res.message || '上传失败,请检查数据', 3000) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
uploadError (err, file, fileList) { |
|
|
|
@ -550,9 +555,7 @@ export default { |
|
|
|
|
this.uploadFaild = false |
|
|
|
|
}, |
|
|
|
|
uploadSure () { |
|
|
|
|
this.init() |
|
|
|
|
this.importVisible = false |
|
|
|
|
this.keyWord = '' |
|
|
|
|
this.$refs.upload.submit(); |
|
|
|
|
}, |
|
|
|
|
// 新增 |
|
|
|
|
add () { |
|
|
|
@ -772,7 +775,8 @@ export default { |
|
|
|
|
}, |
|
|
|
|
responseType: 'blob' |
|
|
|
|
}).then((res) => { |
|
|
|
|
util.downloadFileDirect(`报名人员.xls`, new Blob([res.data])) |
|
|
|
|
const name = res.headers['content-disposition'] |
|
|
|
|
util.downloadFileDirect(name ? decodeURI(name) : '报名人员.xlsx', new Blob([res.data])) |
|
|
|
|
}).catch(res => { }) |
|
|
|
|
} else { |
|
|
|
|
axios.get(`${this.api.excelExport}?competitionId=${this.id}`, { |
|
|
|
@ -781,7 +785,8 @@ export default { |
|
|
|
|
}, |
|
|
|
|
responseType: 'blob' |
|
|
|
|
}).then((res) => { |
|
|
|
|
util.downloadFileDirect(`报名人员.xls`, new Blob([res.data])) |
|
|
|
|
const name = res.headers['content-disposition'] |
|
|
|
|
util.downloadFileDirect(name ? decodeURI(name) : '报名人员.xlsx', new Blob([res.data])) |
|
|
|
|
}).catch(res => { }) |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|