yumeng пре 1 година
родитељ
комит
fcd3ea78f0

+ 33 - 33
ruixuan-live/src/main/resources/mapper/isc/SupplyChainMapper.xml

@@ -29,7 +29,7 @@
         sum(case when send_status = 0 and order_status != 80 then 1 else 0 end) as 'notDeliveryNum',
         round(sum(case when send_status = 1 and order_status != 80 then 1 else 0 end) / sum(case when order_status != 80
         then 1 else 0 end),4) as 'deliveryRadio',
-        sum(case when order_status != 80 then mcn_promotion_amount else 0 end) as 'regimentalPromotionAmount'
+        sum(case when order_status != 80 then regimental_promotion_amount else 0 end) as 'regimentalPromotionAmount'
         from kuaishou_supply_chain
         where 1= 1
         <if test="start != null and start != ''">
@@ -251,7 +251,7 @@
         sum(case when order_status = 80 then 1 else 0 end) as 'invalidOrderNUm',
         regimental_promotion_rate as 'regimentalPromotionRate',
         sum(case when order_status != 80 then pay_amount else 0 end) as 'payAmount',
-        sum(case when order_status != 80 then mcn_promotion_amount else 0 end) as 'regimentalPromotionAmount',
+        sum(case when order_status != 80 then regimental_promotion_amount else 0 end) as 'regimentalPromotionAmount',
         sum(case when order_status != 80 then total_regimental_settle_amount else 0 end) as
         'totalRegimentalSettleAmount',
         item_commission_rate as 'itemCommissionRate'
@@ -316,7 +316,7 @@
         select
         sum(order_amount) as 'orderAmount',
         sum(base_amount) as 'baseAmount',
-        sum(case when order_status != 80 then mcn_promotion_amount else 0 end) as 'regimentalPromotionAmount',
+        sum(case when order_status != 80 then regimental_promotion_amount else 0 end) as 'regimentalPromotionAmount',
         sum(case when order_status != 80 then total_regimental_settle_amount else 0 end) as
         'totalRegimentalSettleAmount'
         from kuaishou_supply_chain
@@ -626,7 +626,7 @@
         sum(case when flow_point != 'REFUND' then 1 else 0 end) as 'validOrderNUm',
         round(sum(case when flow_point != 'REFUND' then 1 else 0 end) / count(order_id),4) as 'validRadio'
         from bytedance_order_list
-        where author_short_id is not null
+        where  author_short_id is not null
         <if test="start != null and start != ''">
             and pay_success_time &gt;= #{start}
         </if>
@@ -652,7 +652,7 @@
         then 1 else 0 end) * 100,2) as 'deliveryRadio',
         round(sum(pay_amount) / 100,2) as 'payAmount',
         round(sum(case when order_status != 80 then pay_amount else 0 end) / 100 , 2 ) as 'validPayAmount',
-        round(sum(case when order_status != 80 then mcn_promotion_amount else 0 end) / 100, 2) as
+        round(sum(case when order_status != 80 then regimental_promotion_amount else 0 end) / 100, 2) as
         'regimentalPromotionAmount'
         from kuaishou_supply_chain
         where 1= 1
@@ -831,7 +831,7 @@
         sum(case when t2.order_status = 80 then 1 else 0 end) as 'invalidOrderNUm',
         sum(case when t2.order_status != 80 then t2.pay_amount else 0 end) as 'payAmount',
         sum(case
-        when t2.order_status != 80 then t2.mcn_promotion_amount
+        when t2.order_status != 80 then t2.regimental_promotion_amount
         else 0 end) as 'regimentalPromotionAmount',
         sum(case when t2.order_status != 80 then t2.total_regimental_settle_amount else 0 end) as
         'totalRegimentalSettleAmount'
@@ -924,7 +924,7 @@
         t2.regimental_promotion_rate AS 'regimentalPromotionRate',
         sum(
         CASE
-        WHEN t2.order_status != 80 THEN t2.mcn_promotion_amount
+        WHEN t2.order_status != 80 THEN t2.regimental_promotion_amount
         ELSE 0
         END
         ) AS 'regimentalPromotionAmount',
@@ -1085,7 +1085,7 @@
         ) AS 'payAmount',
         sum(
         CASE
-        WHEN t2.order_status != 80 THEN t2.mcn_promotion_amount
+        WHEN t2.order_status != 80 THEN t2.regimental_promotion_amount
         ELSE 0
         END
         ) AS 'regimentalPromotionAmount',
@@ -1173,7 +1173,7 @@
         round(
         sum(
         CASE
-        WHEN t2.order_status != 80 THEN t2.mcn_promotion_amount
+        WHEN t2.order_status != 80 THEN t2.regimental_promotion_amount
         ELSE 0
         END
         ) / 100 , 2)AS 'regimentalPromotionAmount',
@@ -1220,7 +1220,7 @@
         COUNT(oid) as 'allNumber',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN 1 ELSE 0 END), 0) AS 'validOrderNUm',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN order_amount ELSE 0 END), 0) AS 'orderAmount',
-        IFNULL(SUM(CASE WHEN order_status != 80 THEN mcn_promotion_amount ELSE 0 END),0) AS
+        IFNULL(SUM(CASE WHEN order_status != 80 THEN regimental_promotion_amount ELSE 0 END),0) AS
         'regimentalPromotionAmount',
         IFNULL(sum(base_amount), 0) as 'baseAmount'
         FROM kuaishou_supply_chain
@@ -1264,7 +1264,7 @@
         COUNT(oid) as 'allNumber',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN 1 ELSE 0 END), 0) AS 'validOrderNUm',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN order_amount ELSE 0 END), 0) AS 'orderAmount',
-        IFNULL(SUM(CASE WHEN order_status != 80 THEN mcn_promotion_amount ELSE 0 END),0) AS
+        IFNULL(SUM(CASE WHEN order_status != 80 THEN regimental_promotion_amount ELSE 0 END),0) AS
         'regimentalPromotionAmount',
         IFNULL(sum(base_amount), 0) as 'baseAmount',
         IFNULL(COUNT(CASE WHEN send_status = 1 THEN oid ELSE null END), 0) AS 'sendCount'
@@ -1364,7 +1364,7 @@
         count(1) AS 'orderCount',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN 1 ELSE 0 END), 0) AS 'validOrderCount',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN order_amount ELSE 0 END),0) AS 'orderAmount',
-        IFNULL(SUM(CASE WHEN order_status != 80 THEN mcn_promotion_amount ELSE 0 END),0) AS
+        IFNULL(SUM(CASE WHEN order_status != 80 THEN regimental_promotion_amount ELSE 0 END),0) AS
         'regimentalPromotionAmount',
         COUNT(DISTINCT promoter_id) as 'promoterCount'
         FROM kuaishou_supply_chain t1
@@ -1406,7 +1406,7 @@
         count(1) AS 'orderCount',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN 1 ELSE 0 END), 0) AS 'validOrderCount',
         IFNULL(SUM(CASE WHEN order_status != 80 THEN order_amount ELSE 0 END),0) AS 'orderAmount',
-        IFNULL(SUM(CASE WHEN order_status != 80 THEN mcn_promotion_amount ELSE 0 END),0) AS
+        IFNULL(SUM(CASE WHEN order_status != 80 THEN regimental_promotion_amount ELSE 0 END),0) AS
         'regimentalPromotionAmount'
         FROM kuaishou_supply_chain
         WHERE order_create_time >= #{startLong}
@@ -1453,7 +1453,7 @@
         (
         SELECT
         IFNULL(SUM(order_amount),0) AS 'orderAmount',
-        IFNULL(SUM(mcn_promotion_amount),0) AS 'regimentalPromotionAmount'
+        IFNULL(SUM(regimental_promotion_amount),0) AS 'regimentalPromotionAmount'
         FROM kuaishou_supply_chain t1
         WHERE order_status != 80
         <if test='promoterIds != null and promoterIds.size() > 0'>
@@ -1468,7 +1468,7 @@
         (
         SELECT
         IFNULL(SUM(order_amount),0) AS 'orderAmount',
-        IFNULL(SUM(mcn_promotion_amount),0) AS 'regimentalPromotionAmount'
+        IFNULL(SUM(regimental_promotion_amount),0) AS 'regimentalPromotionAmount'
         FROM kuaishou_supply_chain t1
         WHERE order_status != 80
         <if test='promoterIds != null and promoterIds.size() > 0'>
@@ -1533,7 +1533,7 @@
         (
         SELECT
         IFNULL(SUM(order_amount),0) AS 'orderAmount',
-        IFNULL(SUM(mcn_promotion_amount),0) AS 'regimentalPromotionAmount',
+        IFNULL(SUM(regimental_promotion_amount),0) AS 'regimentalPromotionAmount',
         COUNT(oid) as 'orderCount'
         FROM kuaishou_supply_chain t1
         WHERE order_status != 80
@@ -1551,7 +1551,7 @@
         (
         SELECT
         IFNULL(SUM(order_amount),0) AS 'orderAmount',
-        IFNULL(SUM(mcn_promotion_amount),0) AS 'regimentalPromotionAmount',
+        IFNULL(SUM(regimental_promotion_amount),0) AS 'regimentalPromotionAmount',
         COUNT(oid) as 'orderCount'
         FROM kuaishou_supply_chain t1
         WHERE order_status != 80
@@ -1648,8 +1648,8 @@
         round(sum(valid_order_num) / sum(order_num) * 100, 2) as 'validOrderRate',
         sum(order_amount) as 'orderAmount',
         IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN order_amount ELSE 0 END), 0) AS 'voucherOrderAmount',
-        sum(mcn_promotion_amount) as 'regimentalPromotionAmount',
-        IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN mcn_promotion_amount ELSE 0 END), 0)
+        sum(regimental_promotion_amount) as 'regimentalPromotionAmount',
+        IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN regimental_promotion_amount ELSE 0 END), 0)
         AS'voucherRegimentalPromotionAmount',
         sum(total_regimental_settle_amount) as 'totalRegimentalSettleAmount',
         IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN total_regimental_settle_amount ELSE 0 END), 0) AS
@@ -1727,7 +1727,7 @@
         sum(valid_order_num) as 'validOrderNum',
         round(sum(valid_order_num) / sum(order_num) * 100, 2) as 'validOrderRate',
         sum(order_amount) as 'orderAmount',
-        sum(mcn_promotion_amount) as 'regimentalPromotionAmount',
+        sum(regimental_promotion_amount) as 'regimentalPromotionAmount',
         sum(total_regimental_settle_amount) as 'totalRegimentalSettleAmount'
         from ruixuan.promoter_item_order_count
         where 1 = 1
@@ -1768,7 +1768,7 @@
         sum(valid_order_num) as 'validOrderNum',
         round(sum(valid_order_num) / sum(order_num) * 100, 2) as 'validOrderRate',
         sum(order_amount) as 'orderAmount',
-        sum(mcn_promotion_amount) as 'regimentalPromotionAmount',
+        sum(regimental_promotion_amount) as 'regimentalPromotionAmount',
         sum(total_regimental_settle_amount) as 'totalRegimentalSettleAmount'
         from ruixuan.promoter_item_order_count
         where 1 = 1
@@ -1813,7 +1813,7 @@
         sum(valid_order_num) as 'validOrderNum',
         round(sum(valid_order_num) / sum(order_num) * 100, 2) as 'validOrderRate',
         sum(order_amount) as 'orderAmount',
-        sum(mcn_promotion_amount) as 'regimentalPromotionAmount',
+        sum(regimental_promotion_amount) as 'regimentalPromotionAmount',
         sum(total_regimental_settle_amount) as 'totalRegimentalSettleAmount'
         from ruixuan.promoter_item_order_count
         where 1 = 1
@@ -1885,8 +1885,8 @@
         round(sum(valid_order_num) / sum(order_num) * 100, 2) as 'validOrderRate',
         sum(order_amount) as 'orderAmount',
         IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN order_amount ELSE 0 END), 0) AS 'voucherOrderAmount',
-        sum(mcn_promotion_amount) as 'regimentalPromotionAmount',
-        IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN mcn_promotion_amount ELSE 0 END), 0)
+        sum(regimental_promotion_amount) as 'regimentalPromotionAmount',
+        IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN regimental_promotion_amount ELSE 0 END), 0)
         AS'voucherRegimentalPromotionAmount',
         sum(total_regimental_settle_amount) as 'totalRegimentalSettleAmount',
         IFNULL(SUM(CASE WHEN sample_voucher_status = 2 THEN total_regimental_settle_amount ELSE 0 END), 0) AS
@@ -1957,7 +1957,7 @@
         sum(case when t2.order_status = 80 then 1 else 0 end) as 'invalidOrderNUm',
         round(sum(case when t2.order_status != 80 then t2.pay_amount else 0 end) / 100 , 2) as 'payAmount',
         round(sum(case
-        when t2.order_status != 80 then t2.mcn_promotion_amount
+        when t2.order_status != 80 then t2.regimental_promotion_amount
         else 0 end) / 100, 2 )as 'regimentalPromotionAmount',
         round(sum(case when t2.order_status != 80 then t2.total_regimental_settle_amount else 0 end) / 100 , 2) as
         'totalRegimentalSettleAmount'
@@ -2014,7 +2014,7 @@
         sum(case when t2.order_status = 80 then 1 else 0 end) as 'invalidOrderNUm',
         sum(case when t2.order_status != 80 then t2.pay_amount else 0 end) as 'payAmount',
         sum(case
-        when t2.order_status != 80 then t2.mcn_promotion_amount
+        when t2.order_status != 80 then t2.regimental_promotion_amount
         else 0 end) as 'regimentalPromotionAmount',
         sum(case when t2.order_status != 80 then t2.total_regimental_settle_amount else 0 end) as
         'totalRegimentalSettleAmount'
@@ -2024,7 +2024,7 @@
         order_status,
         send_status,
         pay_amount,
-        mcn_promotion_amount,
+        regimental_promotion_amount,
         total_regimental_settle_amount
         from kuaishou_supply_chain
         where order_create_time &gt;= #{start}) t2
@@ -2062,7 +2062,7 @@
         sum(case when t2.order_status = 80 then 1 else 0 end) as 'invalidOrderNUm',
         round(sum(case when t2.order_status != 80 then t2.pay_amount else 0 end) / 100 , 2) as 'payAmount',
         round(sum(case
-        when t2.order_status != 80 then t2.mcn_promotion_amount
+        when t2.order_status != 80 then t2.regimental_promotion_amount
         else 0 end) / 100, 2 )as 'regimentalPromotionAmount',
         round(sum(case when t2.order_status != 80 then t2.total_regimental_settle_amount else 0 end) / 100 , 2) as
         'totalRegimentalSettleAmount'
@@ -2072,7 +2072,7 @@
         order_status,
         send_status,
         pay_amount,
-        mcn_promotion_amount,
+        regimental_promotion_amount,
         total_regimental_settle_amount
         from kuaishou_supply_chain
         where order_create_time &gt;= #{start}) t2
@@ -2110,7 +2110,7 @@
         sum(t2.valid_order_num) as 'validOrderNum',
         concat(round(sum(t2.valid_order_num) / sum(t2.order_num) * 100, 2), '%') as 'validOrderRate',
         round(sum(t2.order_amount) / 100, 2) as 'orderAmount',
-        round(sum(t2.mcn_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
+        round(sum(t2.regimental_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
         round(sum(t2.total_regimental_settle_amount) / 100, 2) as 'totalRegimentalSettleAmount'
         from promoter_bind_channel_date t1
         left join promoter_item_order_count t2
@@ -2166,7 +2166,7 @@
         sum(t2.valid_order_num) as 'validOrderNum',
         concat(round(sum(t2.valid_order_num) / sum(t2.order_num) * 100, 2), '%') as 'validOrderRate',
         round(sum(t2.order_amount) / 100, 2) as 'orderAmount',
-        round(sum(t2.mcn_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
+        round(sum(t2.regimental_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
         round(sum(t2.total_regimental_settle_amount) / 100, 2) as 'totalRegimentalSettleAmount'
         from promoter_bind_channel_date t1
         left join promoter_item_order_count t2
@@ -2197,7 +2197,7 @@
         sum(t2.valid_order_num) as 'validOrderNum',
         concat(round(sum(t2.valid_order_num) / sum(t2.order_num) * 100, 2), '%') as 'validOrderRate',
         round(sum(t2.order_amount) / 100, 2) as 'orderAmount',
-        round(sum(t2.mcn_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
+        round(sum(t2.regimental_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
         round(sum(t2.total_regimental_settle_amount) / 100, 2) as 'totalRegimentalSettleAmount'
         from promoter_bind_channel_date t1
         left join promoter_item_order_count t2
@@ -2236,7 +2236,7 @@
         sum(t2.valid_order_num) as 'validOrderNum',
         concat(round(sum(t2.valid_order_num) / sum(t2.order_num) * 100, 2), '%') as 'validOrderRate',
         round(sum(t2.order_amount) / 100, 2) as 'orderAmount',
-        round(sum(t2.mcn_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
+        round(sum(t2.regimental_promotion_amount) / 100, 2) as 'regimentalPromotionAmount',
         round(sum(t2.total_regimental_settle_amount) / 100, 2) as 'totalRegimentalSettleAmount'
         from kuaishou_promoter t1
         left join(select *

+ 2 - 2
ruixuan-live/src/main/resources/mapper/jiaoyang/JiaoYangReportMapper.xml

@@ -97,7 +97,7 @@
         then 1
         else 0 end),
         4) as 'deliveryRadio',
-        sum(case when order_status != 80 then regimental_promotion_amount else 0 end) as 'regimentalPromotionAmount'
+        sum(case when order_status != 80 then mcn_promotion_amount else 0 end) as 'regimentalPromotionAmount'
         from jy_order_list
         where 1 = 1
         <if test="start != null and start != '' ">
@@ -280,7 +280,7 @@
         select
         sum(order_amount) as 'orderAmount',
         sum(base_amount) as 'baseAmount',
-        sum(case when order_status != 80 then regimental_promotion_amount else 0 end) as 'regimentalPromotionAmount',
+        sum(case when order_status != 80 then mcn_promotion_amount else 0 end) as 'regimentalPromotionAmount',
         sum(case when order_status != 80 then total_regimental_settle_amount else 0 end) as
         'totalRegimentalSettleAmount'
         from jy_order_list