kpi开户数统计fix+团队交易量不屏蔽禁用BD

master
james.zhao 5 years ago
parent 642ef5e8a5
commit 3ea6fdd4ba

@ -13,7 +13,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jib-maven-plugin.version>1.1.2</jib-maven-plugin.version>
<docker-image.version>1.1.5</docker-image.version>
<docker-image.version>1.1.6</docker-image.version>
</properties>
<dependencies>

@ -55,7 +55,7 @@ public interface FinancialBDPrizeLogMapper {
"\tsc.org_id = 1 \n" +
"\tAND o.date >= #{start_date} \n" +
"\tAND o.date < #{end_date} \n" +
"\tAND d.start_date <= o.date AND d.is_valid = 1 AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\tAND d.start_date <= o.date AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\t) \n" +
"\tAND c.get_prize = 1 \n" +
"\tAND c.manager_id = #{manager_id}")
@ -103,7 +103,7 @@ public interface FinancialBDPrizeLogMapper {
"\tsc.org_id = 1 \n" +
"\tAND o.date >= #{start_date} \n" +
"\tAND o.date < #{end_date} \n" +
"\tAND d.start_date <= o.date AND d.is_valid = 1 AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\tAND d.start_date <= o.date AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\t) \n" +
"\tAND c.bd_group IS NOT NULL \n" +
"GROUP BY\n" +
@ -128,7 +128,7 @@ public interface FinancialBDPrizeLogMapper {
"\tsc.org_id = 1 \n" +
"\tAND o.date >= #{start_date} \n" +
"\tAND o.date < #{end_date} \n" +
"\tAND d.start_date <= o.date AND d.is_valid = 1 AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\tAND d.start_date <= o.date AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\t) \n" +
"\tAND c.bd_group IS NOT NULL \n" +
"GROUP BY\n" +
@ -148,7 +148,7 @@ public interface FinancialBDPrizeLogMapper {
"\tsc.org_id = 1 \n" +
"\tAND o.date >= #{month_start_date} \n" +
"\tAND o.date < #{end_date} \n" +
"\tAND d.start_date <= o.date AND d.is_valid = 1 AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\tAND d.start_date <= o.date AND ( d.end_date IS NULL OR d.end_date > o.date \n" +
"\t) \n" +
"\tAND c.bd_group IS NOT NULL \n" +
"GROUP BY\n" +

@ -555,11 +555,11 @@
fbc.bd_type,
sum( a.proportion ) clients_month
FROM
sys_client_bd a
INNER JOIN (
(
SELECT
bd_id,
max( create_time ) create_time
max( create_time ) create_time,
proportion
FROM
sys_client_bd
WHERE
@ -581,12 +581,9 @@
GROUP BY
bd_id,
client_id
) b ON a.bd_id = b.bd_id
AND a.create_time = b.create_time
) a
INNER JOIN financial_bd_config c ON a.bd_id = c.manager_id
INNER JOIN financial_bd_config fbc ON fbc.manager_id = c.bd_group
WHERE
a.is_valid = 1
GROUP BY
fbc.bd_group
ORDER BY
@ -599,11 +596,11 @@
fbc.bd_type,
sum( a.proportion ) clients_yesterday
FROM
sys_client_bd a
INNER JOIN (
(
SELECT
bd_id,
max( create_time ) create_time
max( create_time ) create_time,
proportion
FROM
sys_client_bd
WHERE
@ -625,12 +622,9 @@
GROUP BY
bd_id,
client_id
) b ON a.bd_id = b.bd_id
AND a.create_time = b.create_time
) a
INNER JOIN financial_bd_config c ON a.bd_id = c.manager_id
INNER JOIN financial_bd_config fbc ON fbc.manager_id = c.bd_group
WHERE
a.is_valid = 1
GROUP BY
fbc.bd_group
ORDER BY

Loading…
Cancel
Save