From 3fa4ecc74f689a1e365659e100f97460b53bb44c Mon Sep 17 00:00:00 2001 From: wangsixiang <2970484253@qq.com> Date: Mon, 12 Aug 2024 11:58:55 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=BC=E5=87=BA=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/DcPublishManageController.java | 11 ------- .../zc/business/domain/DcPublishManage.java | 29 +++++++++++-------- 2 files changed, 17 insertions(+), 23 deletions(-) diff --git a/zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java b/zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java index 66513f3a..0f175c20 100644 --- a/zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java +++ b/zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java @@ -344,17 +344,6 @@ public class DcPublishManageController extends BaseController @Log(title = "信息发布管理记录", businessType = BusinessType.EXPORT) @PostMapping("/export") public void export(HttpServletResponse response,@RequestBody DcPublishManage dcPublishManage) throws UnsupportedEncodingException { - String percentEncodedFileName= URLEncoder.encode("公众服务统计.xlsx", StandardCharsets.UTF_8.toString()).replaceAll("\\+", "%20"); - StringBuilder contentDispositionValue = new StringBuilder(); - contentDispositionValue.append("attachment; filename=") - .append(percentEncodedFileName) - .append(";") - .append("filename*=") - .append("utf-8''") - .append(percentEncodedFileName); - response.addHeader("Access-Control-Expose-Headers", "Content-Disposition,download-filename"); - response.setHeader("Content-disposition", contentDispositionValue.toString()); - response.setHeader("download-filename", percentEncodedFileName); List list = dcPublishManageService.selectDcPublishManageExport(dcPublishManage); ExcelUtil util = new ExcelUtil<>(DcPublishManage.class); util.exportExcel(response, list, UniversalEnum.INFORMATION_RELEASE_MANAGEMENT_RECORD_DATA.getValue()); diff --git a/zc-business/src/main/java/com/zc/business/domain/DcPublishManage.java b/zc-business/src/main/java/com/zc/business/domain/DcPublishManage.java index bd6f2074..194e6666 100644 --- a/zc-business/src/main/java/com/zc/business/domain/DcPublishManage.java +++ b/zc-business/src/main/java/com/zc/business/domain/DcPublishManage.java @@ -41,12 +41,25 @@ public class DcPublishManage extends BaseEntity @Excel(name = "发布渠道",readConverterExp="1=手机短信,2=微信公众号,3=微博,4=情报板,5=服务网站,6=微信小程序,7=语音广播,8=企业微信") private Integer publishChannels; + /** 发布时间 */ + @Excel(name = "发布时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") + private Date publishTime; + + //位置 + @Excel(name = "位置/设备") + private String position; + + /** 事件详情 */ + @Excel(name = "发布内容") + private String contentDetails; + /** 审核状态:0-待审核1-已审核2-未通过 */ //@Excel(name = "审核状态: 0-待审核 1-已审核 2-未通过") private Integer isverify; /** 发布者 */ - @Excel(name = "发布者") + @Excel(name = "发布人") private String publisher; /** 审核者1 */ @@ -75,18 +88,12 @@ public class DcPublishManage extends BaseEntity //@Excel(name = "审核者2意见") private String auditComment2; - /** 发布时间 */ - @Excel(name = "发布时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone="GMT+8") - private Date publishTime; + /** 发布状态:1-成功2-失败3-草稿 */ - @Excel(name = "发布状态",readConverterExp="1=成功,2=失败,3=草稿") + @Excel(name = "发布结果",readConverterExp="1=成功,2=失败,3=草稿") private Integer publishStatus; - /** 事件详情 */ - @Excel(name = "内容") - private String contentDetails; //@Excel(name = "方向", readConverterExp = "1=菏泽方向,3=济南方向") private String direction; @@ -123,9 +130,7 @@ public class DcPublishManage extends BaseEntity - //位置 - @Excel(name = "位置/设备") - private String position; + public String getPosition() { return position;