From 02a11da1ca0523e4f8e3d7273904da816f951ffc Mon Sep 17 00:00:00 2001
From: 李林 <z1292839451@163.com>
Date: 星期五, 22 三月 2024 01:54:36 +0800
Subject: [PATCH] 系统调整

---
 data-server/src/main/resources/mapper/DataReportingMapper.xml |   31 ++++++++++++++++++++++++-------
 1 files changed, 24 insertions(+), 7 deletions(-)

diff --git a/data-server/src/main/resources/mapper/DataReportingMapper.xml b/data-server/src/main/resources/mapper/DataReportingMapper.xml
index 08cfa56..65a8d00 100644
--- a/data-server/src/main/resources/mapper/DataReportingMapper.xml
+++ b/data-server/src/main/resources/mapper/DataReportingMapper.xml
@@ -54,14 +54,31 @@
     </select>
     <select id="selectRegistrantCountDtoPageList" resultType="com.yuanchu.mom.dto.RegistrantCountDto">
         select * from (
-        select id, department, registrant, product, name, sum(show_num) show_num, sum(click) click,
-        sum(account_consumption)account_consumption, sum(rebate_consumption)
-        rebate_consumption,(sum(rebate_consumption)+sum(remark)) rebate_consumption2, sum(discounted_consumption)
-        discounted_consumption, sum(fans_add) fans_add, sum(actual_cost) actual_cost, sum(customer_costs)
-        customer_costs, sum(profit) profit, sum(agent_rebate) agent_rebate, sum(customer_rebate) customer_rebate,
-        sum(remark) remark, create_time, update_time, create_user
+        select department,
+        registrant,
+        name2,
+        product,
+        name,
+        sum(show_num)                           show_num,
+        sum(click)                              click,
+        sum(account_consumption)                account_consumption,
+        sum(rebate_consumption)
+        rebate_consumption,
+        (sum(rebate_consumption) + sum(remark)) rebate_consumption2,
+        sum(discounted_consumption)
+        discounted_consumption,
+        sum(fans_add)                           fans_add,
+        sum(actual_cost)                        actual_cost,
+        sum(customer_costs)
+        customer_costs,
+        sum(profit)                             profit,
+        sum(agent_rebate)                       agent_rebate,
+        sum(customer_rebate)                    customer_rebate,
+        sum(remark)                             remark,
+        date_format(create_time, '%Y-%m-%d')    create_time,
+        create_user
         from data_reporting
-        group by registrant,date_format(create_time, '%Y-%m-%d')
+        group by name2,product, date_format(create_time, '%Y-%m-%d')
         ) a
         <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''">
             ${ew.customSqlSegment}

--
Gitblit v1.9.3