From 6ad7505d2ac8b51b9b4cde4851563b243cf87068 Mon Sep 17 00:00:00 2001 From: zhaoyongnian <541231643@qq.com> Date: Mon, 6 Jun 2022 15:21:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/base/community/communityTable.vue | 80 +++++++++++++++++-- 1 file changed, 75 insertions(+), 5 deletions(-) diff --git a/src/views/modules/base/community/communityTable.vue b/src/views/modules/base/community/communityTable.vue index 5eb4596f..147411a2 100644 --- a/src/views/modules/base/community/communityTable.vue +++ b/src/views/modules/base/community/communityTable.vue @@ -66,7 +66,7 @@ 导出 + @click="handleExportOpen">导出 批量删除 - 导出一户一档 + @click="handleExportYihuyidang()">导出一户一档 --> @@ -183,6 +183,31 @@ @dialogOk="addFormOk"> + +
+ 导出房屋数据 + 导出一户一档 + 导出一户一码 +
+ + 取 消 + 确 定 + +
+ @@ -225,7 +250,9 @@ export default { fileName: "", uploadUlr: window.SITE_CONFIG['apiURL'] + '/gov/org/neighborhood/import', yihuyidangDisabled: false, - + yihuyimaDisabled: false, + exportBtn: false, + dialogVisible: false // 导出 } }, components: { @@ -486,7 +513,11 @@ export default { // this.download(res.data, '1.png') }) }, - //导出表格 + // 导出按钮点击事件 + handleExportOpen () { + this.dialogVisible = true + }, + //导出表格 以前是导出 现在改成导出房屋数据 async handleExport () { let title = this.agencyObj.label title = title + '—小区列表' @@ -512,6 +543,10 @@ export default { }, + handleClose(done) { + this.dialogVisible = false + }, + // 下载文件 download (data, downFileName) { if (!data) { @@ -609,6 +644,41 @@ export default { }, + // 导出一户一码 + + handleExportYihuyima () { + this.exportBtn = true + this.yihuyimaDisabled = true + let title = this.agencyObj.label + title = title + '-一户一码' + let url = "/gov/org/house/downloadZip" + + + let params = { + level: this.agencyObj.level, + id: this.agencyObj.id + } + + + + app.ajax.exportFilePost( + url, + params, + (data, rspMsg) => { + + this.download(data, title + '.Zip') + this.exportBtn = false + this.yihuyimaDisabled = false + }, + (rspMsg, data) => { + this.exportBtn = false + this.yihuyimaDisabled = false + this.$message.error(rspMsg); + } + ); + }, + + // 上传文件之前的钩子 beforeUpload (file, type) {