From 794546783a941be444319d98b1947dac23d65c2b Mon Sep 17 00:00:00 2001
From: 44323 <443237572@qq.com>
Date: 星期二, 10 十月 2023 16:22:56 +0800
Subject: [PATCH] 后台代码

---
 cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java |  568 +++++++++++++++++++------------------
 .idea/workspace.xml                                                                                             |  265 +++++++---------
 cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java                                       |    8 
 3 files changed, 411 insertions(+), 430 deletions(-)

diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 8080553..2808ca5 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -25,29 +25,51 @@
     <select />
   </component>
   <component name="ChangeListManager">
-    <list default="true" id="cb08d02f-fd4f-4fa2-85fe-abd508fa83ac" name="Default Changelist" comment="10.8。1">
+    <list default="true" id="cb08d02f-fd4f-4fa2-85fe-abd508fa83ac" name="Default Changelist" comment="10.8">
       <change beforePath="$PROJECT_DIR$/.idea/misc.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/misc.xml" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/controller/FinanceController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/controller/FinanceController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/feignclient/competition/DeductionCompetitionsClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/feignclient/competition/DeductionCompetitionsClient.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/feignclient/course/CoursePackageClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/feignclient/course/CoursePackageClient.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/feignclient/other/SiteClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/feignclient/other/SiteClient.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/mapper/RechargeRecordsMapper.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/mapper/RechargeRecordsMapper.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/model/IncomeQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/model/IncomeQuery.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/model/query/RechargeRecordsQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/model/query/RechargeRecordsQuery.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/service/impl/RechargeRecordsServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/service/impl/RechargeRecordsServiceImpl.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/util/httpClinet/HttpClientUtil.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/java/com/dsh/account/util/httpClinet/HttpClientUtil.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-account/src/main/resources/mapper/RechargeRecordsMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-account/src/main/resources/mapper/RechargeRecordsMapper.xml" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/mapper/PaymentCompetitionMapper.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/mapper/PaymentCompetitionMapper.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/model/CompetitionQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/model/CompetitionQuery.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/service/IPaymentCompetitionService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/service/IPaymentCompetitionService.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/PaymentCompetitionServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/PaymentCompetitionServiceImpl.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-competition/src/main/resources/mapper/PaymentCompetitionMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-competition/src/main/resources/mapper/PaymentCompetitionMapper.xml" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CourseController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CourseController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackageController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackageController.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackagePaymentController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackagePaymentController.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/entity/TAppUser.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/entity/TAppUser.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/mapper/TCoursePackagePaymentMapper.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/model/RegisterOrderQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/model/RegisterOrderQuery.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/TCoursePackagePaymentService.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-course/src/main/resources/mapper/TCoursePackagePaymentMapper.xml" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/account/FinanceClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/account/FinanceClient.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/competition/model/CompetitionQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/competition/model/CompetitionQuery.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseClient.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/course/feignClient/course/CourseClient.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/OperatorController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/OperatorController.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TDiscountController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TDiscountController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TSiteController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TSiteController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/IncomeQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/IncomeQuery.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/RechargeRecordsQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/RechargeRecordsQuery.java" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/RegisterOrderQuery.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/RegisterOrderQuery.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/TGameConfig.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/model/TGameConfig.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/ball/ball_pre_add.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/ball/ball_pre_add.html" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/ball/ball_pre_edit.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/ball/ball_pre_edit.html" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/dataStatistics/platformIncome.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/dataStatistics/platformIncome.html" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/ticket/ticket_add.html" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-management/src/main/webapp/WEB-INF/view/system/ticket/ticket_add.html" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/controller/BallController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/controller/BallController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/controller/SiteController.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/controller/SiteController.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/mapper/SiteBookingMapper.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/mapper/SiteBookingMapper.java" afterDir="false" />
@@ -55,6 +77,7 @@
       <change beforePath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/service/impl/SiteBookingServiceImpl.java" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-other/src/main/java/com/dsh/other/service/impl/SiteBookingServiceImpl.java" afterDir="false" />
       <change beforePath="$PROJECT_DIR$/cloud-server-other/src/main/resources/mapper/SiteBookingMapper.xml" beforeDir="false" afterPath="$PROJECT_DIR$/cloud-server-other/src/main/resources/mapper/SiteBookingMapper.xml" afterDir="false" />
     </list>
+    <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
     <option name="SHOW_DIALOG" value="false" />
     <option name="HIGHLIGHT_CONFLICTS" value="true" />
     <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
@@ -84,7 +107,7 @@
     <option name="generalSettings">
       <MavenGeneralSettings>
         <option name="localRepository" value="C:\Users\45438\.m2\repository" />
-        <option name="mavenHome" value="$PROJECT_DIR$/../../apache-maven-3.9.3" />
+        <option name="mavenHome" value="E:/apache-maven-3.9.3" />
         <option name="userSettingsFile" value="C:\Users\45438\.m2\settings.xml" />
       </MavenGeneralSettings>
     </option>
@@ -95,66 +118,52 @@
   <component name="ProblemsViewState">
     <option name="selectedTabId" value="ProjectErrors" />
   </component>
-  <component name="ProjectColorInfo">{
-  &quot;associatedIndex&quot;: 2
-}</component>
   <component name="ProjectId" id="2T0poWYlZShlnPso29uxjn4gQQo" />
   <component name="ProjectLevelVcsManager" settingsEditedManually="true">
-    <ConfirmationsSetting value="1" id="Add" />
+    <ConfirmationsSetting value="2" id="Add" />
   </component>
   <component name="ProjectViewState">
     <option name="hideEmptyMiddlePackages" value="true" />
     <option name="showLibraryContents" value="true" />
   </component>
-  <component name="PropertiesComponent">{
-  &quot;keyToString&quot;: {
-    &quot;DefaultHtmlFileTemplate&quot;: &quot;HTML File&quot;,
-    &quot;RequestMappingsPanelOrder0&quot;: &quot;0&quot;,
-    &quot;RequestMappingsPanelOrder1&quot;: &quot;1&quot;,
-    &quot;RequestMappingsPanelWidth0&quot;: &quot;75&quot;,
-    &quot;RequestMappingsPanelWidth1&quot;: &quot;75&quot;,
-    &quot;RunOnceActivity.OpenProjectViewOnStart&quot;: &quot;true&quot;,
-    &quot;RunOnceActivity.ShowReadmeOnStart&quot;: &quot;true&quot;,
-    &quot;WebServerToolWindowFactoryState&quot;: &quot;false&quot;,
-    &quot;git-widget-placeholder&quot;: &quot;master&quot;,
-    &quot;ignore.virus.scanning.warn.message&quot;: &quot;true&quot;,
-    &quot;last_opened_file_path&quot;: &quot;D:/jdk&quot;,
-    &quot;node.js.detected.package.eslint&quot;: &quot;true&quot;,
-    &quot;node.js.detected.package.tslint&quot;: &quot;true&quot;,
-    &quot;node.js.selected.package.eslint&quot;: &quot;(autodetect)&quot;,
-    &quot;node.js.selected.package.tslint&quot;: &quot;(autodetect)&quot;,
-    &quot;nodejs_package_manager_path&quot;: &quot;npm&quot;,
-    &quot;project.structure.last.edited&quot;: &quot;项目&quot;,
-    &quot;project.structure.proportion&quot;: &quot;0.15&quot;,
-    &quot;project.structure.side.proportion&quot;: &quot;0.54367816&quot;,
-    &quot;service.view.auto.scroll.to.source&quot;: &quot;true&quot;,
-    &quot;settings.editor.selected.configurable&quot;: &quot;preferences.pluginManager&quot;,
-    &quot;spring.configuration.checksum&quot;: &quot;6e27eb92c8707375af194da5aa857bbc&quot;,
-    &quot;vue.rearranger.settings.migration&quot;: &quot;true&quot;
-  }
-}</component>
+  <component name="PropertiesComponent">
+    <property name="RequestMappingsPanelOrder0" value="0" />
+    <property name="RequestMappingsPanelOrder1" value="1" />
+    <property name="RequestMappingsPanelWidth0" value="75" />
+    <property name="RequestMappingsPanelWidth1" value="75" />
+    <property name="WebServerToolWindowFactoryState" value="false" />
+    <property name="aspect.path.notification.shown" value="true" />
+    <property name="nodejs_package_manager_path" value="npm" />
+    <property name="project.structure.last.edited" value="Project" />
+    <property name="project.structure.proportion" value="0.0" />
+    <property name="project.structure.side.proportion" value="0.2" />
+    <property name="settings.editor.selected.configurable" value="project.propVCSSupport.Confirmation" />
+  </component>
   <component name="ReactorSettings">
     <option name="notificationShown" value="true" />
   </component>
   <component name="RecentsManager">
-    <key name="CopyFile.RECENT_KEYS">
-      <recent name="D:\javaproject\play\cloud-server-parent" />
-      <recent name="D:\Javaproject\PlayPay\cloud-server-management\src\main\webapp\WEB-INF\view\system\ball" />
-      <recent name="D:\Javaproject\PlayPay\cloud-server-account\src\test\java\com\dsh" />
-      <recent name="D:\Javaproject\PlayPay\cloud-server-management\src\main\webapp\static\modular\system\ball" />
-      <recent name="D:\Javaproject\PlayPay\cloud-server-course\src\main\resources\mapper" />
-    </key>
     <key name="MoveFile.RECENT_KEYS">
       <recent name="D:\JavaTool\PlayPai1\cloud-server-management\src\main\webapp\static\modular\system\tStudent" />
       <recent name="D:\JavaTool\PlayPai1\cloud-server-parent" />
       <recent name="D:\ttt\java\PlayPai\cloud-server-parent" />
     </key>
     <key name="CopyClassDialog.RECENTS_KEY">
+      <recent name="com.dsh.course.feignClient.account.model" />
+      <recent name="com.dsh.guns.modular.system.model.dto" />
       <recent name="com.dsh.course.mapper" />
       <recent name="com.dsh.course.service.impl" />
       <recent name="com.dsh.course.service" />
       <recent name="com.dsh.guns.modular.system.service.impl" />
       <recent name="com.dsh.guns.modular.system.service" />
+      <recent name="com.dsh.other.mapper" />
+    </key>
+    <key name="CopyFile.RECENT_KEYS">
+      <recent name="D:\javaproject\play\cloud-server-parent" />
+      <recent name="D:\Javaproject\PlayPay\cloud-server-management\src\main\webapp\WEB-INF\view\system\ball" />
+      <recent name="D:\Javaproject\PlayPay\cloud-server-account\src\test\java\com\dsh" />
+      <recent name="D:\Javaproject\PlayPay\cloud-server-management\src\main\webapp\static\modular\system\ball" />
+      <recent name="D:\Javaproject\PlayPay\cloud-server-course\src\main\resources\mapper" />
     </key>
   </component>
   <component name="RunDashboard">
@@ -163,8 +172,18 @@
         <option value="SpringBootApplicationConfigurationType" />
       </set>
     </option>
+    <option name="ruleStates">
+      <list>
+        <RuleState>
+          <option name="name" value="ConfigurationTypeDashboardGroupingRule" />
+        </RuleState>
+        <RuleState>
+          <option name="name" value="StatusDashboardGroupingRule" />
+        </RuleState>
+      </list>
+    </option>
   </component>
-  <component name="RunManager" selected="Spring Boot.ManagementApplication">
+  <component name="RunManager" selected="Spring Boot.GatewayApplication">
     <configuration name="BigDecimalToChineseWords" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true">
       <option name="MAIN_CLASS_NAME" value="com.dsh.guns.modular.system.util.BigDecimalToChineseWords" />
       <module name="mb-cloud-management" />
@@ -204,8 +223,8 @@
     </configuration>
     <configuration name="AccountApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
       <module name="mb-cloud-account" />
-      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <option name="SPRING_BOOT_MAIN_CLASS" value="com.dsh.AccountApplication" />
+      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <method v="2">
         <option name="Make" enabled="true" />
       </method>
@@ -220,8 +239,8 @@
     </configuration>
     <configuration name="ActivityApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
       <module name="mb-cloud-activity" />
-      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <option name="SPRING_BOOT_MAIN_CLASS" value="com.dsh.ActivityApplication" />
+      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <method v="2">
         <option name="Make" enabled="true" />
       </method>
@@ -235,16 +254,16 @@
     </configuration>
     <configuration name="CompetitionApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
       <module name="mb-cloud-competition" />
-      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <option name="SPRING_BOOT_MAIN_CLASS" value="com.dsh.CompetitionApplication" />
+      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <method v="2">
         <option name="Make" enabled="true" />
       </method>
     </configuration>
     <configuration name="CourseApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
       <module name="mb-cloud-course" />
-      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <option name="SPRING_BOOT_MAIN_CLASS" value="com.dsh.CourseApplication" />
+      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <method v="2">
         <option name="Make" enabled="true" />
       </method>
@@ -257,10 +276,10 @@
       </method>
     </configuration>
     <configuration name="ManagementApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
-      <option name="ENABLE_JMX_AGENT" value="false" />
       <module name="mb-cloud-management" />
-      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <option name="SPRING_BOOT_MAIN_CLASS" value="com.dsh.ManagementApplication" />
+      <option name="ENABLE_JMX_AGENT" value="false" />
+      <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <method v="2">
         <option name="Make" enabled="true" />
       </method>
@@ -272,13 +291,6 @@
         <option name="Make" enabled="true" />
       </method>
     </configuration>
-    <configuration name="UserApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
-      <module name="mb-cloud-user" />
-      <option name="SPRING_BOOT_MAIN_CLASS" value="com.dsh.UserApplication" />
-      <method v="2">
-        <option name="Make" enabled="true" />
-      </method>
-    </configuration>
     <configuration default="true" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot">
       <option name="SHORTEN_COMMAND_LINE" value="MANIFEST" />
       <method v="2">
@@ -286,26 +298,45 @@
       </method>
     </configuration>
     <list>
+      <item itemvalue="Application.BigDecimalToChineseWords" />
       <item itemvalue="JUnit.AccountApplicationTests.contextLoads" />
       <item itemvalue="Spring Boot.ManagementApplication" />
       <item itemvalue="Spring Boot.GatewayApplication" />
       <item itemvalue="Spring Boot.OtherApplication" />
-      <item itemvalue="Spring Boot.UserApplication" />
       <item itemvalue="Spring Boot.AccountApplication" />
       <item itemvalue="Spring Boot.ActivityApplication" />
       <item itemvalue="Spring Boot.AuthApplication" />
       <item itemvalue="Spring Boot.CourseApplication" />
       <item itemvalue="Spring Boot.CompetitionApplication" />
-      <item itemvalue="应用程序.BigDecimalToChineseWords" />
     </list>
     <recent_temporary>
       <list>
         <item itemvalue="JUnit.AccountApplicationTests.contextLoads" />
-        <item itemvalue="应用程序.BigDecimalToChineseWords" />
       </list>
     </recent_temporary>
   </component>
-  <component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="应用程序级" UseSingleDictionary="true" transferred="true" />
+  <component name="ServiceViewManager">
+    <option name="allServicesViewState">
+      <serviceView>
+        <option name="contentProportion" value="0.21049784" />
+        <treeState>
+          <expand>
+            <path>
+              <item name="services root" type="e789fda9:ObjectUtils$Sentinel" />
+              <item name="com.intellij.execution.services.ServiceModel$ServiceGroupNode@a01c4d91" type="7427dc5b:ServiceModel$ServiceGroupNode" />
+            </path>
+            <path>
+              <item name="services root" type="e789fda9:ObjectUtils$Sentinel" />
+              <item name="com.intellij.execution.services.ServiceModel$ServiceGroupNode@a01c4d91" type="7427dc5b:ServiceModel$ServiceGroupNode" />
+              <item name="com.intellij.execution.services.ServiceModel$ServiceGroupNode@a16e2409" type="7427dc5b:ServiceModel$ServiceGroupNode" />
+            </path>
+          </expand>
+          <select />
+        </treeState>
+      </serviceView>
+    </option>
+  </component>
+  <component name="SpellCheckerSettings" BundledDictionaries="0" Folders="0" CustomDictionaries="0" Dictionaries="0" CorrectionsLimit="5" DefaultDictionary="应用程序级" UseSingleDictionary="true" />
   <component name="SvnConfiguration">
     <configuration>C:\Users\luo\AppData\Roaming\Subversion</configuration>
   </component>
@@ -368,6 +399,8 @@
       <workItem from="1696903826401" duration="164000" />
       <workItem from="1696904129011" duration="6673000" />
       <workItem from="1696917635013" duration="5121000" />
+      <workItem from="1696847977356" duration="7435000" />
+      <workItem from="1696898972818" duration="19012000" />
     </task>
     <task id="LOCAL-00001" summary="后台代码删除">
       <created>1690249807612</created>
@@ -680,14 +713,22 @@
     <servers />
   </component>
   <component name="TypeScriptGeneratedFilesManager">
-    <option name="version" value="3" />
+    <option name="version" value="1" />
+    <option name="exactExcludedFiles">
+      <list>
+        <option value="$PROJECT_DIR$/cloud-server-management/node_modules/zrender/index.js" />
+        <option value="$PROJECT_DIR$/cloud-server-management/node_modules/zrender/index.d.ts" />
+      </list>
+    </option>
   </component>
   <component name="Vcs.Log.Tabs.Properties">
     <option name="TAB_STATES">
       <map>
         <entry key="MAIN">
           <value>
-            <State />
+            <State>
+              <option name="COLUMN_ORDER" />
+            </State>
           </value>
         </entry>
       </map>
@@ -741,8 +782,23 @@
         </line-breakpoint>
         <line-breakpoint type="java-line">
           <url>file://$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackagePaymentController.java</url>
-          <line>1360</line>
+          <line>1365</line>
           <option name="timeStamp" value="14" />
+        </line-breakpoint>
+        <line-breakpoint enabled="true" type="java-line">
+          <url>file://$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/controller/CourseController.java</url>
+          <line>472</line>
+          <option name="timeStamp" value="26" />
+        </line-breakpoint>
+        <line-breakpoint enabled="true" type="java-line">
+          <url>file://$PROJECT_DIR$/cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageDiscountServiceImpl.java</url>
+          <line>389</line>
+          <option name="timeStamp" value="27" />
+        </line-breakpoint>
+        <line-breakpoint enabled="true" type="java-line">
+          <url>file://$PROJECT_DIR$/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java</url>
+          <line>251</line>
+          <option name="timeStamp" value="50" />
         </line-breakpoint>
       </breakpoints>
     </breakpoint-manager>
@@ -750,92 +806,5 @@
   <component name="XSLT-Support.FileAssociations.UIState">
     <expand />
     <select />
-  </component>
-  <component name="masterDetails">
-    <states>
-      <state key="ArtifactsStructureConfigurable.UI">
-        <settings>
-          <artifact-editor />
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-      <state key="FacetStructureConfigurable.UI">
-        <settings>
-          <last-edited>No facets are configured</last-edited>
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-      <state key="GlobalLibrariesConfigurable.UI">
-        <settings>
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-      <state key="JdkListConfigurable.UI">
-        <settings>
-          <last-edited>1.8</last-edited>
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-      <state key="ModuleStructureConfigurable.UI">
-        <settings>
-          <last-edited>PlayPai</last-edited>
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-                <option value="0.6" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-      <state key="ProjectJDKs.UI">
-        <settings>
-          <last-edited>1.8</last-edited>
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-      <state key="ProjectLibrariesConfigurable.UI">
-        <settings>
-          <splitter-proportions>
-            <option name="proportions">
-              <list>
-                <option value="0.2" />
-              </list>
-            </option>
-          </splitter-proportions>
-        </settings>
-      </state>
-    </states>
   </component>
 </project>
\ No newline at end of file
diff --git a/cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java b/cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java
index 664a52c..551c246 100644
--- a/cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java
+++ b/cloud-server-account/src/main/java/com/dsh/account/util/PayMoneyUtil.java
@@ -457,9 +457,9 @@
 
 
 
-                  Integer    coursePackagePayments = coursePackageClient.queryByCode(code);
-                  Integer paymentCompetitions = competitionsClient.queryByCode(code);
-                  Integer siteBookings = siteClient.queryByCode(code);
+//                  Integer    coursePackagePayments = coursePackageClient.queryByCode(code);
+//                  Integer paymentCompetitions = competitionsClient.queryByCode(code);
+//                  Integer siteBookings = siteClient.queryByCode(code);
 
 
 
@@ -487,7 +487,7 @@
 
 
 
-
+        return ResultUtil.success();
 
     }
 
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java
index ecf2190..ee240cb 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/DataStatisticsController.java
@@ -128,79 +128,77 @@
             competitionQuery.setInsertType(roleType);
                  incomeQuery.setInsertType(roleType);
                  incomeQuery.setInsertType(roleType);
-
         IncomeVO incomeVO = new IncomeVO();
         List<IncomeVO> incomeVOS = new ArrayList<>();
-                // 会员支付记录
-                List<VipPayment> vipPayments = vipPaymentClient.registrationList(incomeQuery);
-                for (VipPayment vipPayment : vipPayments) {
-                    IncomeVO temp = new IncomeVO();
-                    if (vipPayment.getPayStatus()==1){
-                        temp.setInsertTime(vipPayment.getInsertTime());
-                        incomeVOS.add(temp);
-                    }
-                    if (vipPayment.getAmount() != null) {
-                        temp.setAmount(new BigDecimal(vipPayment.getAmount().toString()));
-                    }
-                }
-                // 充值记录
-                List<RechargeRecordsVO> rechargeRecordsVOS = financeClient.rechargeList(rechargeRecordsQuery);
-        List<RechargeRecords> rechargeRecords = financeClient.rechargeList1(rechargeRecordsQuery);
-                for (RechargeRecordsVO rechargeRecordsVO : rechargeRecordsVOS) {
-                    IncomeVO temp = new IncomeVO();
-                    temp.setInsertTime(rechargeRecordsVO.getInsertTime());
-                    if (rechargeRecordsVO.getAmount() != null) {
-                        temp.setAmount(rechargeRecordsVO.getAmount());
-                    }
-                    if (rechargeRecordsVO.getPayStatus() ==1){
-                        incomeVOS.add(temp);
-                    }
+        // 会员支付记录
+        List<VipPayment> vipPayments = vipPaymentClient.registrationList(incomeQuery);
+        for (VipPayment vipPayment : vipPayments) {
+            IncomeVO temp = new IncomeVO();
+            if (vipPayment.getPayStatus()==1){
+                temp.setInsertTime(vipPayment.getInsertTime());
+                incomeVOS.add(temp);
+            }
+            if (vipPayment.getAmount() != null) {
+                temp.setAmount(new BigDecimal(vipPayment.getAmount().toString()));
+            }
+        }
+        // 充值记录
+        List<RechargeRecordsVO> rechargeRecordsVOS = financeClient.rechargeList(rechargeRecordsQuery);
+        for (RechargeRecordsVO rechargeRecordsVO : rechargeRecordsVOS) {
+            IncomeVO temp = new IncomeVO();
+            temp.setInsertTime(rechargeRecordsVO.getInsertTime());
+            if (rechargeRecordsVO.getAmount() != null) {
+                temp.setAmount(rechargeRecordsVO.getAmount());
+            }
+            if (rechargeRecordsVO.getPayStatus() ==1){
+                incomeVOS.add(temp);
+            }
 
-                }
-                // 报名课程记录
-                List<RegisterOrderVO> registerOrderVOS = coursePackagePaymentClient.listAllRegister(query);
-                for (RegisterOrderVO registerOrderVO : registerOrderVOS) {
-                    if (registerOrderVO.getMoney() == null) {
-                        continue;
-                    }
-                    IncomeVO temp = new IncomeVO();
-                    temp.setInsertTime(registerOrderVO.getInsertTime());
-                    if (registerOrderVO.getMoney() != null) {
-                        temp.setAmount(registerOrderVO.getMoney());
-                    }
-                    if (registerOrderVO.getPayStatus()==2){
-                        incomeVOS.add(temp);
-                    }
-                }
-                    // 报名活动
-                    List<PaymentCompetition> competitions = competitionClient.listAllPayment(competitionQuery);
-                    for (PaymentCompetition competition : competitions) {
-                        if (competition.getPayStatus() != 2) {
-                            continue;
-                        }
-                        if (competition.getPayType()==3 || competition.getPayType()==4){
-                            continue;
-                        }
-                        IncomeVO temp = new IncomeVO();
-                        temp.setInsertTime(competition.getInsertTime());
-                        if (competition.getAmount() != null) {
-                            temp.setAmount(new BigDecimal(competition.getAmount().toString()));
-                        }
-                        incomeVOS.add(temp);
-                    }
-                // 预约场地
-                List<SiteBooking> siteBookings = siteClient.listAll(siteBookingQuery);
-                for (SiteBooking siteBooking : siteBookings) {
-                    IncomeVO temp = new IncomeVO();
-                    if(siteBooking.getStatus()!=3){
-                        continue;
-                    }
-                    temp.setInsertTime(siteBooking.getPayTime());
-                    if (siteBooking.getPayMoney() != null) {
-                        temp.setAmount(new BigDecimal(siteBooking.getPayMoney().toString()));
-                    }
-                    incomeVOS.add(temp);
-                }
+        }
+        // 报名课程记录
+        List<RegisterOrderVO> registerOrderVOS = coursePackagePaymentClient.listAllRegister(query);
+        for (RegisterOrderVO registerOrderVO : registerOrderVOS) {
+            if (registerOrderVO.getMoney() == null) {
+                continue;
+            }
+            IncomeVO temp = new IncomeVO();
+            temp.setInsertTime(registerOrderVO.getInsertTime());
+            if (registerOrderVO.getMoney() != null) {
+                temp.setAmount(registerOrderVO.getMoney());
+            }
+            if (registerOrderVO.getPayStatus()==2){
+                incomeVOS.add(temp);
+            }
+        }
+        // 报名活动
+        List<PaymentCompetition> competitions = competitionClient.listAllPayment(competitionQuery);
+        for (PaymentCompetition competition : competitions) {
+            if (competition.getPayStatus() != 2) {
+                continue;
+            }
+            if (competition.getPayType()==3 || competition.getPayType()==4){
+                continue;
+            }
+            IncomeVO temp = new IncomeVO();
+            temp.setInsertTime(competition.getInsertTime());
+            if (competition.getAmount() != null) {
+                temp.setAmount(new BigDecimal(competition.getAmount().toString()));
+            }
+            incomeVOS.add(temp);
+        }
+        // 预约场地
+        List<SiteBooking> siteBookings = siteClient.listAll(siteBookingQuery);
+        for (SiteBooking siteBooking : siteBookings) {
+            IncomeVO temp = new IncomeVO();
+            if(siteBooking.getStatus()!=3){
+                continue;
+            }
+            temp.setInsertTime(siteBooking.getPayTime());
+            if (siteBooking.getPayMoney() != null) {
+                temp.setAmount(new BigDecimal(siteBooking.getPayMoney().toString()));
+            }
+            incomeVOS.add(temp);
+        }
         // 积分商品
         List<PointMerchandiseIncomeVo> amount = pointMercharsClient.getAmount();
         for (PointMerchandiseIncomeVo pointMerchandiseIncomeVo : amount) {
@@ -211,7 +209,6 @@
                 incomeVOS.add(temp);
             }
         }
-
         // 最终返回的数据
         Map<String, List<Object>> monthlyData = new HashMap<>();
         // 创建一个 Map 用于存储每年的累计 amount
@@ -252,216 +249,231 @@
         for (int i = 0; i < 10; i++) {
             integers1.add(years-i);
         }
-        for (int year = integers1.get(0); year >= integers1.get(integers1.size()-1); year++) {
-            BigDecimal totalAmount = yearToTotalAmountMap.getOrDefault(year, BigDecimal.ZERO);
-            // 创建一个新的 IncomeVO 对象,并设置年份和累计金额
-            IncomeVO resultIncomeVO = new IncomeVO();
-            resultIncomeVO.setAmount(totalAmount);
-            resultIncomeVOS.add(resultIncomeVO);
-        }
-        monthlyData.put("yearIncome",resultIncomeVOS);
-
-        // 创建一个 Map 用于存储今年每个月的累计 amount
-        Map<Integer, BigDecimal> monthToTotalAmountMap = new HashMap<>();
-        Calendar calendar = Calendar.getInstance();
-        int currentYear = calendar.get(Calendar.YEAR);
-        List<BigDecimal> monthlyAmountList = new ArrayList<>(Collections.nCopies(12, BigDecimal.ZERO));
-
-        for (IncomeVO incomeVO1 : incomeVOS) {
-            Calendar calendar1 = Calendar.getInstance();
-            calendar1.setTime(incomeVO1.getInsertTime());
-            int year = calendar1.get(Calendar.YEAR);
-            int month = calendar1.get(Calendar.MONTH) + 1; // 月份从0开始,所以需要加1
-            if (year == currentYear) {
-                BigDecimal totalAmount = monthlyAmountList.get(month - 1);
-                totalAmount = totalAmount.add(incomeVO1.getAmount());
-                monthlyAmountList.set(month - 1, totalAmount);
-            }
-        }
-        monthlyData.put("monthIncome", Collections.singletonList(monthlyAmountList));
-
-        // 获取当前月份
-        LocalDate currentDate = LocalDate.now();
-        int currentMonth = currentDate.getMonthValue();
-        // 初始化一个长度为当前月份的天数的列表,并将每一天的金额初始化为零
-        int daysInCurrentMonth = currentDate.lengthOfMonth();
-        List<BigDecimal> weekAmount = new ArrayList<>();
-
-        // 获取最近四周
-        LocalDateTime minNow = LocalDateTime.now().with(LocalTime.MIN);
-        LocalDateTime maxNow = LocalDateTime.now().with(LocalTime.MAX);
-        // 周度数据
-        LocalDateTime week1Start = minNow.minusDays(6);
-        LocalDateTime week1End = maxNow;
-
-        LocalDateTime week2Start = minNow.minusDays(13);
-        LocalDateTime week2End = minNow.minusDays(7);
-
-        LocalDateTime week3Start = minNow.minusDays(20);
-        LocalDateTime week3End = minNow.minusDays(14);
-
-        LocalDateTime week4Start = minNow.minusDays(27);
-        LocalDateTime week4End = minNow.minusDays(21);
-        // 用于存放四个周的数据
+        List<Object> collect = integers1.stream().sorted().collect(Collectors.toList());
         List<Object> objects1 = new ArrayList<>();
-        // 计算每个周的amount总和
-        BigDecimal tAmount1 = BigDecimal.ZERO;
-        BigDecimal tAmount2 = BigDecimal.ZERO;
-        BigDecimal tAmount3 = BigDecimal.ZERO;
-        BigDecimal tAmount4 = BigDecimal.ZERO;
-        for (IncomeVO incomeVO1 : incomeVOS) {
-            Date insertTime = incomeVO1.getInsertTime();
-            // 将Date转换为LocalDateTime
-            Instant instant = insertTime.toInstant();
-            ZoneId zoneId = ZoneId.systemDefault();
-            LocalDateTime dateTime = instant.atZone(zoneId).toLocalDateTime();
-            // 判断该数据属于哪个周
-            if (dateTime.isAfter(week1Start) && dateTime.isBefore(week1End)) {
-                BigDecimal amount1 = incomeVO1.getAmount();
-                tAmount1=tAmount1.add(amount1);
-            } else if (dateTime.isAfter(week2Start) && dateTime.isBefore(week2End)) {
-                BigDecimal amount1 = incomeVO1.getAmount();
-                tAmount2=tAmount2.add(amount1);
-            } else if (dateTime.isAfter(week3Start) && dateTime.isBefore(week3End)) {
-                BigDecimal amount1 = incomeVO1.getAmount();
-                tAmount4=tAmount3.add(amount1);
-            } else if (dateTime.isAfter(week4Start) && dateTime.isBefore(week4End)) {
-                BigDecimal amount1 = incomeVO1.getAmount();
-                tAmount4=tAmount4.add(amount1);
-            }
+        for (Object o : collect) {
+            BigDecimal orDefault = yearToTotalAmountMap.getOrDefault(Integer.valueOf(o.toString()), BigDecimal.ZERO);
+            objects1.add(orDefault);
         }
-        weekAmount.add(tAmount1);
-        weekAmount.add(tAmount2);
-        weekAmount.add(tAmount3);
-        weekAmount.add(tAmount4);
-        monthlyData.put("weekIncome", Collections.singletonList(weekAmount));
-
-        LocalDateTime currentDateTime = LocalDateTime.now();
-        List<BigDecimal> amountByDay = new ArrayList<>(Collections.nCopies(7, BigDecimal.ZERO));
-        for (IncomeVO incomeVO3 : incomeVOS) {
-            Date insertTime = incomeVO3.getInsertTime();
-            // 将 Date 转换为 LocalDateTime
-            LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
-            // 计算日期与当前日期的差距
-            long daysDifference = ChronoUnit.DAYS.between(insertDateTime.toLocalDate(), currentDateTime.toLocalDate());
-            // 如果日期在七天内,累加金额
-            if (daysDifference >= 0 && daysDifference < 7) {
-                int index = (int) (6 - daysDifference); // 计算对应的索引位置
-                BigDecimal amount3 = incomeVO3.getAmount();
-                BigDecimal updatedAmount = amountByDay.get(index).add(amount3);
-                amountByDay.set(index, updatedAmount);
-
-            }
-        }
-
-        monthlyData.put("dayIncome", Collections.singletonList(amountByDay));
-        // 获取当前日期和时间
-        LocalDateTime now = LocalDateTime.now();
-        // 今年的起始日期和结束日期
-        LocalDateTime startOfYear = now.with(TemporalAdjusters.firstDayOfYear()).with(LocalTime.MIN);
-        LocalDateTime endOfYear = now.with(TemporalAdjusters.lastDayOfYear()).with(LocalTime.MAX);
-        // 本月的起始日期和结束日期
-        LocalDateTime startOfMonth = now.with(TemporalAdjusters.firstDayOfMonth()).with(LocalTime.MIN);
-        LocalDateTime endOfMonth = now.with(TemporalAdjusters.lastDayOfMonth()).with(LocalTime.MAX);
-        // 本周的起始日期和结束日期
-        LocalDateTime startOfWeek = now.with(TemporalAdjusters.previousOrSame(DayOfWeek.MONDAY)).with(LocalTime.MIN);
-        LocalDateTime endOfWeek = now.with(TemporalAdjusters.nextOrSame(DayOfWeek.SUNDAY)).with(LocalTime.MAX);
-        // 今天的起始日期和结束日期
-        LocalDateTime startOfDay = now.with(LocalTime.MIN);
-        LocalDateTime endOfDay = now.with(LocalTime.MAX);
-        // 创建日期格式化器
-        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
-        // 筛选符合条件的IncomeVO对象
-        List<IncomeVO> thisYearIncome = incomeVOS.stream()
-                .filter(income -> {
-                    Date insertTime = income.getInsertTime();
-                    try {
-                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
-                        return insertDateTime.isAfter(startOfYear) && insertDateTime.isBefore(endOfYear);
-                    } catch (Exception e) {
-                        e.printStackTrace();
-                        return false;
-                    }
-                })
-                .collect(Collectors.toList());
-        // 使用 map 方法将 IncomeVO 转换为 BigDecimal,提取出 amount 字段
-        List<BigDecimal> amounts = thisYearIncome.stream()
-                .map(IncomeVO::getAmount)
-                .collect(Collectors.toList());
-        //本年总收入
-        BigDecimal totalAmount = amounts.stream()
-                .reduce(BigDecimal.ZERO, BigDecimal::add);
-        // 用于展示总营收 本年度营收 本月营收 本周营收 本日营收
-        objects.add(totalAmount);
-        List<IncomeVO> thisMonthIncome = incomeVOS.stream()
-                .filter(income -> {
-                    Date insertTime = income.getInsertTime();
-                    try {
-                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
-                        return insertDateTime.isAfter(startOfMonth) && insertDateTime.isBefore(endOfMonth);
-                    } catch (Exception e) {
-                        e.printStackTrace();
-                        return false;
-                    }
-                })
-                .collect(Collectors.toList());
-        List<BigDecimal> amountMonth = thisMonthIncome.stream()
-                .map(IncomeVO::getAmount)
-                .collect(Collectors.toList());
-        // 使用 本月总收入
-        BigDecimal totalMonth = amountMonth.stream()
-                .reduce(BigDecimal.ZERO, BigDecimal::add);
-
-        objects.add(totalMonth);
-        List<IncomeVO> thisWeekIncome = incomeVOS.stream()
-                .filter(income -> {
-                    Date insertTime = income.getInsertTime();
-                    try {
-                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
-                        return insertDateTime.isAfter(startOfWeek) && insertDateTime.isBefore(endOfWeek);
-                    } catch (Exception e) {
-                        e.printStackTrace();
-                        return false;
-                    }
-                })
-                .collect(Collectors.toList());
-        List<BigDecimal> amountWeek = thisWeekIncome.stream()
-                .map(IncomeVO::getAmount)
-                .collect(Collectors.toList());
-        // 使用 本月总收入
-        BigDecimal totalWeek = amountWeek.stream()
-                .reduce(BigDecimal.ZERO, BigDecimal::add);
-        objects.add(totalWeek);
-        List<IncomeVO> todayIncome = incomeVOS.stream()
-                .filter(income -> {
-                    Date insertTime = income.getInsertTime();
-                    try {
-                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
-                        return insertDateTime.isAfter(startOfDay) && insertDateTime.isBefore(endOfDay);
-                    } catch (Exception e) {
-                        e.printStackTrace();
-                        return false;
-                    }
-                })
-                .collect(Collectors.toList());
-        List<BigDecimal> amountToday = todayIncome.stream()
-                .map(IncomeVO::getAmount)
-                .collect(Collectors.toList());
-        // 使用 本月总收入
-        BigDecimal totalToday = amountToday.stream()
-                .reduce(BigDecimal.ZERO, BigDecimal::add);
-        objects.add(totalToday);
-        // 最后put
-        monthlyData.put("yearMount",objects);
-
-        ArrayList<Object> integers = new ArrayList<>();
-        int year = DateUtil.year(new Date());
-        for (int i = 0; i < 10; i++) {
-            integers.add(year-i);
-        }
-        List<Object> collect = integers.stream().sorted().collect(Collectors.toList());
-        monthlyData.put("year",collect);
+//        for (int year = integers1.get(0); year >= integers1.get(integers1.size()-1); year++) {
+//            BigDecimal totalAmount = yearToTotalAmountMap.getOrDefault(year, BigDecimal.ZERO);
+//            // 创建一个新的 IncomeVO 对象,并设置年份和累计金额
+//            IncomeVO resultIncomeVO = new IncomeVO();
+//            resultIncomeVO.setAmount(totalAmount);
+//            resultIncomeVOS.add(resultIncomeVO);
+//        }
+        monthlyData.put("yearIncome",objects1);
         return monthlyData;
+
+
+
+
+
+
+
+
+//
+//        // 创建一个 Map 用于存储今年每个月的累计 amount
+//        Map<Integer, BigDecimal> monthToTotalAmountMap = new HashMap<>();
+//        Calendar calendar = Calendar.getInstance();
+//        int currentYear = calendar.get(Calendar.YEAR);
+//        List<BigDecimal> monthlyAmountList = new ArrayList<>(Collections.nCopies(12, BigDecimal.ZERO));
+//
+//        for (IncomeVO incomeVO1 : incomeVOS) {
+//            Calendar calendar1 = Calendar.getInstance();
+//            calendar1.setTime(incomeVO1.getInsertTime());
+//            int year = calendar1.get(Calendar.YEAR);
+//            int month = calendar1.get(Calendar.MONTH) + 1; // 月份从0开始,所以需要加1
+//            if (year == currentYear) {
+//                BigDecimal totalAmount = monthlyAmountList.get(month - 1);
+//                totalAmount = totalAmount.add(incomeVO1.getAmount());
+//                monthlyAmountList.set(month - 1, totalAmount);
+//            }
+//        }
+//        monthlyData.put("monthIncome", Collections.singletonList(monthlyAmountList));
+//
+//        // 获取当前月份
+//        LocalDate currentDate = LocalDate.now();
+//        int currentMonth = currentDate.getMonthValue();
+//        // 初始化一个长度为当前月份的天数的列表,并将每一天的金额初始化为零
+//        int daysInCurrentMonth = currentDate.lengthOfMonth();
+//        List<BigDecimal> weekAmount = new ArrayList<>();
+//
+//        // 获取最近四周
+//        LocalDateTime minNow = LocalDateTime.now().with(LocalTime.MIN);
+//        LocalDateTime maxNow = LocalDateTime.now().with(LocalTime.MAX);
+//        // 周度数据
+//        LocalDateTime week1Start = minNow.minusDays(6);
+//        LocalDateTime week1End = maxNow;
+//
+//        LocalDateTime week2Start = minNow.minusDays(13);
+//        LocalDateTime week2End = minNow.minusDays(7);
+//
+//        LocalDateTime week3Start = minNow.minusDays(20);
+//        LocalDateTime week3End = minNow.minusDays(14);
+//
+//        LocalDateTime week4Start = minNow.minusDays(27);
+//        LocalDateTime week4End = minNow.minusDays(21);
+//        // 用于存放四个周的数据
+//        List<Object> objects1 = new ArrayList<>();
+//        // 计算每个周的amount总和
+//        BigDecimal tAmount1 = BigDecimal.ZERO;
+//        BigDecimal tAmount2 = BigDecimal.ZERO;
+//        BigDecimal tAmount3 = BigDecimal.ZERO;
+//        BigDecimal tAmount4 = BigDecimal.ZERO;
+//        for (IncomeVO incomeVO1 : incomeVOS) {
+//            Date insertTime = incomeVO1.getInsertTime();
+//            // 将Date转换为LocalDateTime
+//            Instant instant = insertTime.toInstant();
+//            ZoneId zoneId = ZoneId.systemDefault();
+//            LocalDateTime dateTime = instant.atZone(zoneId).toLocalDateTime();
+//            // 判断该数据属于哪个周
+//            if (dateTime.isAfter(week1Start) && dateTime.isBefore(week1End)) {
+//                BigDecimal amount1 = incomeVO1.getAmount();
+//                tAmount1=tAmount1.add(amount1);
+//            } else if (dateTime.isAfter(week2Start) && dateTime.isBefore(week2End)) {
+//                BigDecimal amount1 = incomeVO1.getAmount();
+//                tAmount2=tAmount2.add(amount1);
+//            } else if (dateTime.isAfter(week3Start) && dateTime.isBefore(week3End)) {
+//                BigDecimal amount1 = incomeVO1.getAmount();
+//                tAmount4=tAmount3.add(amount1);
+//            } else if (dateTime.isAfter(week4Start) && dateTime.isBefore(week4End)) {
+//                BigDecimal amount1 = incomeVO1.getAmount();
+//                tAmount4=tAmount4.add(amount1);
+//            }
+//        }
+//        weekAmount.add(tAmount1);
+//        weekAmount.add(tAmount2);
+//        weekAmount.add(tAmount3);
+//        weekAmount.add(tAmount4);
+//        monthlyData.put("weekIncome", Collections.singletonList(weekAmount));
+//
+//        LocalDateTime currentDateTime = LocalDateTime.now();
+//        List<BigDecimal> amountByDay = new ArrayList<>(Collections.nCopies(7, BigDecimal.ZERO));
+//        for (IncomeVO incomeVO3 : incomeVOS) {
+//            Date insertTime = incomeVO3.getInsertTime();
+//            // 将 Date 转换为 LocalDateTime
+//            LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
+//            // 计算日期与当前日期的差距
+//            long daysDifference = ChronoUnit.DAYS.between(insertDateTime.toLocalDate(), currentDateTime.toLocalDate());
+//            // 如果日期在七天内,累加金额
+//            if (daysDifference >= 0 && daysDifference < 7) {
+//                int index = (int) (6 - daysDifference); // 计算对应的索引位置
+//                BigDecimal amount3 = incomeVO3.getAmount();
+//                BigDecimal updatedAmount = amountByDay.get(index).add(amount3);
+//                amountByDay.set(index, updatedAmount);
+//
+//            }
+//        }
+//
+//        monthlyData.put("dayIncome", Collections.singletonList(amountByDay));
+//        // 获取当前日期和时间
+//        LocalDateTime now = LocalDateTime.now();
+//        // 今年的起始日期和结束日期
+//        LocalDateTime startOfYear = now.with(TemporalAdjusters.firstDayOfYear()).with(LocalTime.MIN);
+//        LocalDateTime endOfYear = now.with(TemporalAdjusters.lastDayOfYear()).with(LocalTime.MAX);
+//        // 本月的起始日期和结束日期
+//        LocalDateTime startOfMonth = now.with(TemporalAdjusters.firstDayOfMonth()).with(LocalTime.MIN);
+//        LocalDateTime endOfMonth = now.with(TemporalAdjusters.lastDayOfMonth()).with(LocalTime.MAX);
+//        // 本周的起始日期和结束日期
+//        LocalDateTime startOfWeek = now.with(TemporalAdjusters.previousOrSame(DayOfWeek.MONDAY)).with(LocalTime.MIN);
+//        LocalDateTime endOfWeek = now.with(TemporalAdjusters.nextOrSame(DayOfWeek.SUNDAY)).with(LocalTime.MAX);
+//        // 今天的起始日期和结束日期
+//        LocalDateTime startOfDay = now.with(LocalTime.MIN);
+//        LocalDateTime endOfDay = now.with(LocalTime.MAX);
+//        // 创建日期格式化器
+//        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
+//        // 筛选符合条件的IncomeVO对象
+//        List<IncomeVO> thisYearIncome = incomeVOS.stream()
+//                .filter(income -> {
+//                    Date insertTime = income.getInsertTime();
+//                    try {
+//                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
+//                        return insertDateTime.isAfter(startOfYear) && insertDateTime.isBefore(endOfYear);
+//                    } catch (Exception e) {
+//                        e.printStackTrace();
+//                        return false;
+//                    }
+//                })
+//                .collect(Collectors.toList());
+//        // 使用 map 方法将 IncomeVO 转换为 BigDecimal,提取出 amount 字段
+//        List<BigDecimal> amounts = thisYearIncome.stream()
+//                .map(IncomeVO::getAmount)
+//                .collect(Collectors.toList());
+//        //本年总收入
+//        BigDecimal totalAmount = amounts.stream()
+//                .reduce(BigDecimal.ZERO, BigDecimal::add);
+//        // 用于展示总营收 本年度营收 本月营收 本周营收 本日营收
+//        objects.add(totalAmount);
+//        List<IncomeVO> thisMonthIncome = incomeVOS.stream()
+//                .filter(income -> {
+//                    Date insertTime = income.getInsertTime();
+//                    try {
+//                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
+//                        return insertDateTime.isAfter(startOfMonth) && insertDateTime.isBefore(endOfMonth);
+//                    } catch (Exception e) {
+//                        e.printStackTrace();
+//                        return false;
+//                    }
+//                })
+//                .collect(Collectors.toList());
+//        List<BigDecimal> amountMonth = thisMonthIncome.stream()
+//                .map(IncomeVO::getAmount)
+//                .collect(Collectors.toList());
+//        // 使用 本月总收入
+//        BigDecimal totalMonth = amountMonth.stream()
+//                .reduce(BigDecimal.ZERO, BigDecimal::add);
+//
+//        objects.add(totalMonth);
+//        List<IncomeVO> thisWeekIncome = incomeVOS.stream()
+//                .filter(income -> {
+//                    Date insertTime = income.getInsertTime();
+//                    try {
+//                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
+//                        return insertDateTime.isAfter(startOfWeek) && insertDateTime.isBefore(endOfWeek);
+//                    } catch (Exception e) {
+//                        e.printStackTrace();
+//                        return false;
+//                    }
+//                })
+//                .collect(Collectors.toList());
+//        List<BigDecimal> amountWeek = thisWeekIncome.stream()
+//                .map(IncomeVO::getAmount)
+//                .collect(Collectors.toList());
+//        // 使用 本月总收入
+//        BigDecimal totalWeek = amountWeek.stream()
+//                .reduce(BigDecimal.ZERO, BigDecimal::add);
+//        objects.add(totalWeek);
+//        List<IncomeVO> todayIncome = incomeVOS.stream()
+//                .filter(income -> {
+//                    Date insertTime = income.getInsertTime();
+//                    try {
+//                        LocalDateTime insertDateTime = LocalDateTime.ofInstant(insertTime.toInstant(), ZoneId.systemDefault());
+//                        return insertDateTime.isAfter(startOfDay) && insertDateTime.isBefore(endOfDay);
+//                    } catch (Exception e) {
+//                        e.printStackTrace();
+//                        return false;
+//                    }
+//                })
+//                .collect(Collectors.toList());
+//        List<BigDecimal> amountToday = todayIncome.stream()
+//                .map(IncomeVO::getAmount)
+//                .collect(Collectors.toList());
+//        // 使用 本月总收入
+//        BigDecimal totalToday = amountToday.stream()
+//                .reduce(BigDecimal.ZERO, BigDecimal::add);
+//        objects.add(totalToday);
+//        // 最后put
+//        monthlyData.put("yearMount",objects);
+//
+//        ArrayList<Object> integers = new ArrayList<>();
+//        int year = DateUtil.year(new Date());
+//        for (int i = 0; i < 10; i++) {
+//            integers.add(year-i);
+//        }
+//        List<Object> collect = integers.stream().sorted().collect(Collectors.toList());
+//        monthlyData.put("year",collect);
+//        return monthlyData;
     }
 
 

--
Gitblit v1.7.1