From 3596e1cf3f635975e3cf4b7160d800c45ca7ee81 Mon Sep 17 00:00:00 2001 From: zouyx <1798599149@qq.com> Date: Thu, 14 Nov 2024 20:02:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=81=E4=B8=9A=E7=B1=BB=E5=9E=8B=E7=BB=9F?= =?UTF-8?q?=E8=AE=A1=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../statisticsEnterprise.html | 46 +++++++++++++++++-- 1 file changed, 43 insertions(+), 3 deletions(-) diff --git a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/statisticsEnterprise/statisticsEnterprise.html b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/statisticsEnterprise/statisticsEnterprise.html index f7219467..e4ddf886 100644 --- a/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/statisticsEnterprise/statisticsEnterprise.html +++ b/lib/EmergencyService/zdxtEmergencyBootStart/src/main/resources/templates/project/code/statisticsEnterprise/statisticsEnterprise.html @@ -61,7 +61,7 @@
  •  搜索  重置 - 导出 + 导出 返回
  • @@ -142,7 +142,7 @@

    -
  • 导出
  • +
  • 导出
  • @@ -506,7 +506,47 @@ eSearch2(); timeType2(); } - + function downloadI1(){ + var currentId=$('form').eq(0).attr('id'); + var params = $.common.formToJSON(currentId); + $.ajax({ + type: "POST", + data: JSON.stringify(params), + contentType: 'application/json', + //设置响应类型 + xhrFields: {responseType: "blob"}, + url: prefix+"/export1", + success: function (result) { + const link = document.createElement('a'); + let blob = new Blob([result], {type: 'application/vnd.ms-excel'}); + link.style.display = 'none'; + link.href = URL.createObjectURL(blob); + link.setAttribute('download', "执法检查统计.xls"); + document.body.appendChild(link); + link.click(); + document.body.removeChild(link) + } + }) + } + function downloadI2(){ + $.ajax({ + type: "POST", + contentType: 'application/json', + //设置响应类型 + xhrFields: {responseType: "blob"}, + url: prefix+"/export2", + success: function (result) { + const link = document.createElement('a'); + let blob = new Blob([result], {type: 'application/vnd.ms-excel'}); + link.style.display = 'none'; + link.href = URL.createObjectURL(blob); + link.setAttribute('download', "企业类型统计.xls"); + document.body.appendChild(link); + link.click(); + document.body.removeChild(link) + } + }) + } /*******echarts:企业类型/占比*********/ /* const ecsh = echarts.init(document.getElementById("echartEnterprise"));