diff --git a/src/views/personnelEfficiencyManagement/performanceManagement/components/reportingPerf.vue b/src/views/personnelEfficiencyManagement/performanceManagement/components/reportingPerf.vue index 7e2a2620..da97db66 100644 --- a/src/views/personnelEfficiencyManagement/performanceManagement/components/reportingPerf.vue +++ b/src/views/personnelEfficiencyManagement/performanceManagement/components/reportingPerf.vue @@ -45,7 +45,7 @@ import { readExcelBsEfficiencyTask, reportBsEfficiencyTask, subReportBsEfficiencyTask, - removeFile + removeFile, } from '@/api/performanceManagement/dataReporting'; export default { @@ -88,7 +88,7 @@ export default { tableColumn: [], attachId: null, formData: null, - isUploading:false, + isUploading: false, }; }, watch: { @@ -106,7 +106,7 @@ export default { console.log('uploadColumn', uploadColumn); if (uploadColumn) { // this.$set(uploadColumn, 'disabled', disabled); - uploadColumn.disabled = disabled + uploadColumn.disabled = disabled; } }, tableRowClassName({ row }) { @@ -126,7 +126,7 @@ export default { }, uploadBefore(file, done, loading, column) { - console.log('1111111111111111111') + console.log('1111111111111111111'); this.isUploading = true; this.setUploadDisabled(true); this.formData = file; @@ -153,22 +153,23 @@ export default { // this.$message.error('最多只能上传一个文件'); // return // }, - uploadDelete(file, column){ - console.log('file-------------',file) - // removeFile({ - // fileName:file.name - // }).then(res =>{ - // if(res.data.code === 200){ - this.isRead = false - this.attachId = null - this.formData = null - this.excelForm = { excelFile: [] } - this.tableColumn = [] - this.tableData = [] - // }else{ - // this.$message.error(res.data.msg || '删除失败') - // } - // }) + uploadDelete(file, column) { + console.log('file-------------', file); + removeFile({ + fileName: file.name, + }).then(res => { + if (res.data.code === 200) { + this.isRead = false; + this.attachId = null; + this.formData = null; + this.excelForm = { excelFile: [] }; + this.tableColumn = []; + this.tableData = []; + this.$message.success('删除成功'); + } else { + this.$message.error(res.data.msg || '删除失败'); + } + }); }, readExcel() { if (!this.attachId) {