From 99ded4a8ea6c3aa2620dd5861cadebde52b7763b Mon Sep 17 00:00:00 2001 From: jianjun Date: Wed, 2 Mar 2022 16:35:01 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=98=B2=E9=87=8D?= =?UTF-8?q?=E5=A4=8D=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/controller/ArticleController.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java b/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java index d81affca3a..4c7457f4c3 100644 --- a/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java +++ b/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java @@ -19,6 +19,7 @@ package com.epmet.controller; import com.epmet.commons.tools.annotation.LoginUser; import com.epmet.commons.tools.annotation.RequirePermission; +import com.epmet.commons.tools.aop.NoRepeatSubmit; import com.epmet.commons.tools.enums.RequirePermissionEnum; import com.epmet.commons.tools.scan.result.SyncScanResult; import com.epmet.commons.tools.security.dto.TokenDto; @@ -218,6 +219,7 @@ public class ArticleController { * @param formDTO * @throws Exception */ + @NoRepeatSubmit @PostMapping("publish") @RequirePermission(requirePermission = RequirePermissionEnum.WORK_PARTY_VOICE_PUBLISH) public Result publishArticle(@LoginUser TokenDto tokenDto, @RequestBody PublishArticleFormDTO formDTO) throws Exception { @@ -234,6 +236,7 @@ public class ArticleController { * @param formDTO * @throws Exception */ + @NoRepeatSubmit @PostMapping("manualpublish") @RequirePermission(requirePermission = RequirePermissionEnum.WORK_PARTY_VOICE_PUBLISH) public Result manualPublish(@LoginUser TokenDto tokenDto, @RequestBody PublishArticleFormDTO formDTO) throws Exception { From a195f893230c2f08ae6dbfbc743c6029e3fd6f19 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 3 Mar 2022 09:52:53 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E9=A1=B9=E7=9B=AE=E5=88=86=E7=B1=BB?= =?UTF-8?q?=E7=BB=9F=E8=AE=A1=E5=AF=BC=E5=87=BA=E6=96=87=E4=BB=B6=E6=97=A5?= =?UTF-8?q?=E6=9C=9F=E4=B8=8D=E5=AF=B9=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../datareport/controller/screen/ScreenProjectController.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/controller/screen/ScreenProjectController.java b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/controller/screen/ScreenProjectController.java index 5b9e5c314d..28cf89d084 100644 --- a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/controller/screen/ScreenProjectController.java +++ b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/datareport/controller/screen/ScreenProjectController.java @@ -204,6 +204,7 @@ public class ScreenProjectController { //tokenDto.setUserId("36bc0fb38565ecdebf8ab9b476b44548"); //tokenDto.setCustomerId("45687aa479955f9d06204d415238f7cc"); ValidatorUtils.validateEntity(formDTO, ProjectCategoryFormDTO.CategoryProjectExportForm.class); + String openTime = formDTO.getStartTime(); List data = screenProjectService.selectProjectCategory(formDTO, tokenDto); String templatePath = "excel/project_category_temp.xlsx"; @@ -216,7 +217,7 @@ public class ScreenProjectController { Map mapData = new HashMap<>(); mapData.put("list",resultDTOList); mapData.put("orgName", formDTO.getOrgName()); - mapData.put("exportDate",getExportDateStr(formDTO.getStartTime(),formDTO.getEndTime())); + mapData.put("exportDate", getExportDateStr(openTime, formDTO.getEndTime())); Workbook workbook = ExcelExportUtil.exportExcel(new TemplateExportParams(templatePath), mapData); response.setHeader("content-Type", "application/vnd.ms-excel"); response.addHeader("Content-Disposition", "attachment;fileName=" + URLEncoder.encode("项目分类统计.xls", "UTF-8"));