From 54a48d7d5997fba08280948f7096c88ded596461 Mon Sep 17 00:00:00 2001 From: cst61 Date: Sat, 25 Apr 2026 23:39:18 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=8A=A5=E8=A1=A8=E7=9A=84?= =?UTF-8?q?=E9=A3=8E=E6=A0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/LbDailyUserTradeReportController.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/rj/controller/LbDailyUserTradeReportController.java b/src/main/java/com/rj/controller/LbDailyUserTradeReportController.java index c9905ae..e22b494 100644 --- a/src/main/java/com/rj/controller/LbDailyUserTradeReportController.java +++ b/src/main/java/com/rj/controller/LbDailyUserTradeReportController.java @@ -30,8 +30,11 @@ import org.apache.poi.ss.usermodel.ComparisonOperator; import org.apache.poi.ss.usermodel.ConditionalFormattingRule; import org.apache.poi.ss.usermodel.FontFormatting; import org.apache.poi.ss.util.CellRangeAddress; +import org.apache.poi.xssf.usermodel.XSSFCellStyle; +import org.apache.poi.xssf.usermodel.XSSFColor; import org.apache.poi.xssf.usermodel.XSSFWorkbook; +import java.awt.Color; import java.math.BigDecimal; import java.math.RoundingMode; import java.net.URLEncoder; @@ -458,7 +461,6 @@ public class LbDailyUserTradeReportController { CellStyle zebraTextStyle = workbook.createCellStyle(); zebraTextStyle.cloneStyleFrom(textStyle); - zebraTextStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex()); zebraTextStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND); CellStyle intStyle = workbook.createCellStyle(); @@ -472,9 +474,13 @@ public class LbDailyUserTradeReportController { CellStyle zebraIntStyle = workbook.createCellStyle(); zebraIntStyle.cloneStyleFrom(intStyle); - zebraIntStyle.setFillForegroundColor(IndexedColors.GREY_25_PERCENT.getIndex()); zebraIntStyle.setFillPattern(FillPatternType.SOLID_FOREGROUND); + // 更淡的斑马纹底色(接近白色) + XSSFColor zebraFill = new XSSFColor(new Color(242, 244, 248), null); + ((XSSFCellStyle) zebraTextStyle).setFillForegroundColor(zebraFill); + ((XSSFCellStyle) zebraIntStyle).setFillForegroundColor(zebraFill); + CellStyle summaryTextStyle = workbook.createCellStyle(); summaryTextStyle.cloneStyleFrom(textStyle); summaryTextStyle.setFillForegroundColor(IndexedColors.LEMON_CHIFFON.getIndex());