|
@@ -33,6 +33,7 @@
|
|
|
</el-dropdown>
|
|
|
<el-button type="primary" class="margin-left_10 margin-right_10" size="small" @click="showField">显示栏位管理</el-button>
|
|
|
<el-button v-if="$permission.FunPermissions('xiaoshi/IPREmail')" type="primary" class="margin-right_10" size="small" @click="IPREmail">联系邮箱</el-button>
|
|
|
+ <el-button type="primary" v-if="componentType==2 && $permission.FunPermissions('xiaoshi/exportReportList')" class="margin-right_10" size="small" :loading="exportBtnLoading" @click="exportExcel">导 出</el-button>
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
@@ -82,6 +83,7 @@ import patentShare from '@/views/components/drawer/Share.vue';
|
|
|
|
|
|
import IPREmailDialog from '../InvalidResponse/components/dialog/IPREmail.vue'
|
|
|
import handlePersonDialog from './dialog/handlePerson.vue'
|
|
|
+import { formatDate,downLoad } from '@/utils';
|
|
|
export default {
|
|
|
components: {
|
|
|
Table,
|
|
@@ -182,7 +184,8 @@ export default {
|
|
|
label:'被动',
|
|
|
value:0
|
|
|
},
|
|
|
- ]
|
|
|
+ ],
|
|
|
+ exportBtnLoading:false
|
|
|
};
|
|
|
},
|
|
|
watch: {
|
|
@@ -290,6 +293,31 @@ export default {
|
|
|
IPREmail(){
|
|
|
this.$refs.IPREmailDialog.open()
|
|
|
},
|
|
|
+ //导出报告成excel
|
|
|
+ exportExcel(){
|
|
|
+ let params = {
|
|
|
+ searchQuery: this.$commonJS.objectToString(this.searchOption),//检索条件
|
|
|
+ orderDTOList: this.sort,//排序信息
|
|
|
+ }
|
|
|
+ params.ifInvalidReport = 0
|
|
|
+ if(this.fixedSearch.reportType){
|
|
|
+ params.ifInvalidReport = 1
|
|
|
+ if(params.searchQuery){
|
|
|
+ params.searchQuery = params.searchQuery + ' and reportType=(' + this.fixedSearch.reportType.join(' OR ') + ')'
|
|
|
+ }else{
|
|
|
+ params.searchQuery ='reportType=(' + this.fixedSearch.reportType.join(' OR ') + ')'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.exportBtnLoading = true
|
|
|
+ this.$api.exportReportList(params).then(response=>{
|
|
|
+ this.exportBtnLoading = false
|
|
|
+ let now = formatDate(new Date(),"YYYY-MM-DD")
|
|
|
+ downLoad(response,now + '- 无效案件详情表.xlsx')
|
|
|
+ }).catch(error=>{
|
|
|
+ this.$message.error('导出失败')
|
|
|
+ this.exportBtnLoading = false
|
|
|
+ })
|
|
|
+ },
|
|
|
//标签页点击
|
|
|
async tabChange(name){
|
|
|
var type = Number(name)
|