From 2a31b6bf020f10d23ade9d09a656dca86f301f3f Mon Sep 17 00:00:00 2001
From: java110 <928255095@qq.com>
Date: 星期一, 19 十月 2020 15:25:01 +0800
Subject: [PATCH] 优化代码
---
service-report/src/main/java/com/java110/report/api/ReportFeeMonthStatisticsApi.java | 51 ++++++++++++++++++++++++++++++++++++++++++++++-----
1 files changed, 46 insertions(+), 5 deletions(-)
diff --git a/service-report/src/main/java/com/java110/report/api/ReportFeeMonthStatisticsApi.java b/service-report/src/main/java/com/java110/report/api/ReportFeeMonthStatisticsApi.java
index 0688cb2..8b131bb 100644
--- a/service-report/src/main/java/com/java110/report/api/ReportFeeMonthStatisticsApi.java
+++ b/service-report/src/main/java/com/java110/report/api/ReportFeeMonthStatisticsApi.java
@@ -9,14 +9,13 @@
import com.java110.report.bmo.reportFeeMonthStatistics.IUpdateReportFeeMonthStatisticsBMO;
import com.java110.utils.util.Assert;
import com.java110.utils.util.BeanConvertUtil;
+import com.java110.utils.util.DateUtil;
import com.java110.utils.util.StringUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestMethod;
-import org.springframework.web.bind.annotation.RequestParam;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Calendar;
@RestController
@@ -284,4 +283,46 @@
}
+ /**
+ * 鏌ヨ璐圭敤鍒嗛」琛�
+ *
+ * @param communityId 灏忓尯ID
+ * @return
+ * @serviceCode /reportFeeMonthStatistics/queryPrePaymentCount
+ * @path /app/reportFeeMonthStatistics/queryPrePaymentCount
+ */
+ @RequestMapping(value = "/queryPrePaymentCount", method = RequestMethod.GET)
+ public ResponseEntity<String> queryPrePaymentCount(@RequestParam(value = "communityId") String communityId) {
+ ReportFeeMonthStatisticsDto reportFeeMonthStatisticsDto = new ReportFeeMonthStatisticsDto();
+ reportFeeMonthStatisticsDto.setCommunityId(communityId);
+ reportFeeMonthStatisticsDto.setStartTime(DateUtil.getNow(DateUtil.DATE_FORMATE_STRING_A));
+ Calendar calendar = Calendar.getInstance();
+ calendar.add(Calendar.DAY_OF_MONTH, 7);
+ reportFeeMonthStatisticsDto.setEndTime(DateUtil.getFormatTimeString(calendar.getTime(), DateUtil.DATE_FORMATE_STRING_A));
+ return getReportFeeMonthStatisticsBMOImpl.queryPrePaymentCount(reportFeeMonthStatisticsDto);
+ }
+
+ /**
+ * 鏌ヨ璐圭敤鍒嗛」琛�
+ *
+ * @param communityId 灏忓尯ID
+ * @return
+ * @serviceCode /reportFeeMonthStatistics/queryPrePayment
+ * @path /app/reportFeeMonthStatistics/queryPrePayment
+ */
+ @RequestMapping(value = "/queryPrePayment", method = RequestMethod.GET)
+ public ResponseEntity<String> queryPrePayment(@RequestParam(value = "communityId") String communityId,
+ @RequestParam(value = "page") int page,
+ @RequestParam(value = "row") int row) {
+ ReportFeeMonthStatisticsDto reportFeeMonthStatisticsDto = new ReportFeeMonthStatisticsDto();
+ reportFeeMonthStatisticsDto.setCommunityId(communityId);
+ reportFeeMonthStatisticsDto.setPage(page);
+ reportFeeMonthStatisticsDto.setRow(row);
+ reportFeeMonthStatisticsDto.setStartTime(DateUtil.getNow(DateUtil.DATE_FORMATE_STRING_A));
+ Calendar calendar = Calendar.getInstance();
+ calendar.add(Calendar.DAY_OF_MONTH, 7);
+ reportFeeMonthStatisticsDto.setEndTime(DateUtil.getFormatTimeString(calendar.getTime(), DateUtil.DATE_FORMATE_STRING_A));
+ return getReportFeeMonthStatisticsBMOImpl.queryPrePayment(reportFeeMonthStatisticsDto);
+ }
+
}
--
Gitblit v1.8.0