From 7168485a57c7975a7c82e3769469f50cb2bfba72 Mon Sep 17 00:00:00 2001 From: yishiqihuasheng <1191093413@qq.com> Date: Thu, 18 May 2023 19:11:40 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E7=90=86=E6=89=8B=E5=B7=A5=E8=AE=A4?= =?UTF-8?q?=E8=AF=81mapper=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dxhy/core/thread/ManualAthensThread.java | 42 ------------------- .../src/main/resources/mapper/FpZhMapper.xml | 2 +- 2 files changed, 1 insertion(+), 43 deletions(-) diff --git a/dxhy-core/src/main/java/com/dxhy/core/thread/ManualAthensThread.java b/dxhy-core/src/main/java/com/dxhy/core/thread/ManualAthensThread.java index e74c4640..600c2f1a 100644 --- a/dxhy-core/src/main/java/com/dxhy/core/thread/ManualAthensThread.java +++ b/dxhy-core/src/main/java/com/dxhy/core/thread/ManualAthensThread.java @@ -339,48 +339,6 @@ public class ManualAthensThread extends BaseThread { } - /** - * 递归导出数据到excel文件,防止jvm oom - * - * @param pramsMap - * 查询数据参数集合 - * @param curr - * 当前第几页 - * @param excelFile - * 导出的文件 - * @param writer - * @throws Exception - * - */ - - private boolean detailCicleExport(Map pramsMap, int curr, String excelFile, OutputStream out, - ExcelWriter writer) throws Exception { - // 查询指定页数的数据 - JSONObject pageData = rzFpxxService.getTaxRebateList(pramsMap, curr, default_size); - boolean hasNext = pageData.getBooleanValue("hasNext"); - List dataList = (List)pageData.get("datalist"); - boolean firstPage = false; - if (curr == default_curr) { - firstPage = true; - } - - // 数据不是最后一页 - if (hasNext) { - int nextPage = pageData.getIntValue("nextPage"); - // 写入当前页数据 - exportListArrayToExcel(excelFile, title, detailTitleColumns, dataList, firstPage, false, 2, "货物信息", out, - writer); - // 更新页数 - return detailCicleExport(pramsMap, nextPage, excelFile, out, writer); - } else { - // 写入最后一页数据 - exportListArrayToExcel(excelFile, title, detailTitleColumns, dataList, firstPage, true, 2, "货物信息", out, - writer); - return hasNext; - } - - } - public void exportListArrayToExcel(String excelFile, String title, String[] titleColumns, List dataList, boolean firstPage, boolean lastPage, int sheetNo, String sheetName, OutputStream out, ExcelWriter writer) { diff --git a/dxhy-core/src/main/resources/mapper/FpZhMapper.xml b/dxhy-core/src/main/resources/mapper/FpZhMapper.xml index f753a78a..aebfad4c 100644 --- a/dxhy-core/src/main/resources/mapper/FpZhMapper.xml +++ b/dxhy-core/src/main/resources/mapper/FpZhMapper.xml @@ -495,7 +495,7 @@ ,t.qs_type,t.qs_status,t.dk_tax_amount,t.qs_name,t.sn_voucher_number,t.posting_time,t.image_id,t.account_period, case date_format(t.invoice_date,'%Y%m%d') between c.select_start_date and c.select_end_date when true then 1 - else 2 end authStatus,t.bzdh,t.tax_amount + else 2 end authStatus,t.bzdh, t.inaccount_status,t.payment_status,DATE_FORMAT(t.payment_date,'%Y-%m-%d')payment_date,t.settlement_no,t.ele_invoice_no from t_dx_record_invoice t left join t_dx_tax_current c on t.gf_tax_no = c.taxno left join t_dx_dk_count d on c.taxno = d.taxno and c.current_tax_period = d.skssq