From de3d3d7b3b0e360aeed3e23491f5aeb14f05cecd Mon Sep 17 00:00:00 2001 From: luoyang Date: Mon, 19 Nov 2018 10:26:13 +0800 Subject: [PATCH] add manage-provider --- .../core/impls/EstimateAnalysisServiceImpl.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/core/impls/EstimateAnalysisServiceImpl.java b/src/main/java/au/com/royalpay/payment/manage/analysis/core/impls/EstimateAnalysisServiceImpl.java index c12c98bcb..2a8bd8270 100644 --- a/src/main/java/au/com/royalpay/payment/manage/analysis/core/impls/EstimateAnalysisServiceImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/analysis/core/impls/EstimateAnalysisServiceImpl.java @@ -82,7 +82,15 @@ public class EstimateAnalysisServiceImpl implements EstimateAnalysisService { //今天 Calendar calendar = Calendar.getInstance(); calendar.setTimeZone(TimeZone.getTimeZone("Asia/Shanghai")); - Date todayDate = new Date(); + + //如果是周一,显示周五的数据 + Calendar cal=Calendar.getInstance(); + cal.setTime(new Date()); + int week=cal.get(Calendar.DAY_OF_WEEK); + if (week ==2) { + cal.add(Calendar.DATE, -3); + } + Date todayDate = cal.getTime(); String dateStr = DateFormatUtils.format(todayDate, "yyyy/MM/dd"); if (estimateAnalysisMapper.checkDayIsCleanDay(dateStr) != null) { JSONObject today = getDaySettleInfo(todayDate);