|
|
|
@@ -29,9 +29,13 @@ |
|
|
|
</span> |
|
|
|
<span style="float:right; margin-right: 20px;"> |
|
|
|
<div style="display:inline-block;margin-left: 20px; "> |
|
|
|
<i class="el-icon-download"></i> |
|
|
|
<span ><a id = "download_file" :href= "'../api/v1/projectboard/downloadAll/?type='+this.params.type+'&beginTime='+this.params.beginTime+'&endTime='+this.params.endTime+'&q='+this.params.q+'&sort=openi'" @click="isExport();return false;" >下载报告</a> </span> |
|
|
|
<!-- <span ><a id = "download_file" :href= "downLoadSrc" @click="jugeExport();" target="_black">下载报告</a> </span> --> |
|
|
|
<a class="el-icon-download" v-if="tableData!=''" :href= "'../api/v1/projectboard/downloadAll/?type='+this.params.type+'&beginTime='+this.params.beginTime+'&endTime='+this.params.endTime+'&q='+this.params.q+'&sort=openi'" ></a> |
|
|
|
<i class="el-icon-download" v-else="tableData=''" href="#" style="color:rgba(187, 187, 187, 100);" @click='popMark()'></i> |
|
|
|
<!-- <span ><a id = "download_file" :href= "'../api/v1/projectboard/downloadAll/?type='+this.params.type+'&beginTime='+this.params.beginTime+'&endTime='+this.params.endTime+'&q='+this.params.q+'&sort=openi'" >下载报告</a> </span> --> |
|
|
|
<span > |
|
|
|
<a id = "download_file" v-if="tableData!=''" :href= "'../api/v1/projectboard/downloadAll/?type='+this.params.type+'&beginTime='+this.params.beginTime+'&endTime='+this.params.endTime+'&q='+this.params.q+'&sort=openi'">下载报告</a> |
|
|
|
<a id = "download_file" v-else="tableData=''" href= "#" style="color:rgba(187, 187, 187, 100);" @click='popMark()'>下载报告</a> |
|
|
|
</span> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
@@ -269,8 +273,12 @@ |
|
|
|
</span> |
|
|
|
<span style="float:right; margin-right: 20px;"> |
|
|
|
<div style="display:inline-block;margin-left: 20px;"> |
|
|
|
<i class="el-icon-download"></i> |
|
|
|
<span ><a @click="exportData()">下载报告</a> </span> |
|
|
|
<a v-if="tableDataID!=''" @click="exportData()" class="el-icon-download"></a> |
|
|
|
<a v-else="tableDataID=''" @click="exportData()" style="color:rgba(187, 187, 187, 100);" class="el-icon-download"></a> |
|
|
|
<span > |
|
|
|
<a v-if="tableDataID!=''" @click="exportData()">下载报告</a> |
|
|
|
<a v-else="tableDataID=''" @click="exportData()" style="color:rgba(187, 187, 187, 100);">下载报告</a> |
|
|
|
</span> |
|
|
|
</div> |
|
|
|
</span> |
|
|
|
</div> |
|
|
|
@@ -391,24 +399,22 @@ |
|
|
|
// download_file(){ |
|
|
|
// this.params.type='all' |
|
|
|
// }, |
|
|
|
jugeExport(){ |
|
|
|
if(typeof this.tableData=="undefined" || this.tableData=="null" || this.tableData==""){ |
|
|
|
// let self=this; |
|
|
|
return |
|
|
|
} |
|
|
|
else{ |
|
|
|
// let self=this; |
|
|
|
this.downLoadSrc= '../api/v1/projectboard/downloadAll/?type='+this.params.type+'&beginTime='+this.params.beginTime+'&endTime='+this.params.endTime+'&q='+this.params.q+'&sort=openi'; |
|
|
|
} |
|
|
|
popMark(){ |
|
|
|
alert("数据为空时,不能下载!") |
|
|
|
}, |
|
|
|
exportData(){ |
|
|
|
|
|
|
|
// this.getOneProList(this.pro_id,'all',true,7) |
|
|
|
// this.getOneProList(this.pro_id,'all',false,7) |
|
|
|
// this.fileName() |
|
|
|
this.currentPage=1 |
|
|
|
var saveFileName = this.getFileName() |
|
|
|
export2Excel(this.columns,this.tableDataID,saveFileName) |
|
|
|
if (this.tableDataID!=''){ |
|
|
|
this.currentPage=1 |
|
|
|
var saveFileName = this.getFileName() |
|
|
|
export2Excel(this.columns,this.tableDataID,saveFileName) |
|
|
|
}else{ |
|
|
|
alert("数据为空时,不能下载!") |
|
|
|
} |
|
|
|
|
|
|
|
}, |
|
|
|
getFileName(){ |
|
|
|
|
|
|
|
|