|
|
@@ -436,6 +436,10 @@ export default {
|
|
|
exportExcel (res) {
|
|
|
const data = Object.assign(this.queryData, { columnName: res, projectIds: this.selectList.join(',') })
|
|
|
this.$api.params.exportResult(data).then(res => {
|
|
|
+ if (res.hasOwnProperty('code')) {
|
|
|
+ this.$message.error(res.msg)
|
|
|
+ return
|
|
|
+ }
|
|
|
const url = window.URL.createObjectURL(new Blob([res], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8' }))
|
|
|
const link = document.createElement('a')
|
|
|
link.style.display = 'none'
|
|
|
@@ -452,6 +456,10 @@ export default {
|
|
|
exportExcelTotal (item) {
|
|
|
const data = { projectIds: this.selectList.join(',') }
|
|
|
this.$api.params.summaryExport(Object.assign(item, data)).then(res => {
|
|
|
+ if (res.hasOwnProperty('code')) {
|
|
|
+ this.$message.error(res.msg)
|
|
|
+ return
|
|
|
+ }
|
|
|
const url = window.URL.createObjectURL(new Blob([res], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=utf-8' }))
|
|
|
const link = document.createElement('a')
|
|
|
link.style.display = 'none'
|