Commit 07f5f414 by 杨卫

fix:低单价购入、打折策略订单金额计算使用子订单表数据

1 parent e71cd976
...@@ -228,9 +228,9 @@ ...@@ -228,9 +228,9 @@
resultType="cn.com.glsx.dj.peanalysis.dto.analysis.StrategyOrderStatisticsRespDTO"> resultType="cn.com.glsx.dj.peanalysis.dto.analysis.StrategyOrderStatisticsRespDTO">
select select
count(distinct t1.order_code) orderCount, count(distinct t1.order_code) orderCount,
sum(ifnull(t1.total_price, 0)) totalPrice, sum(ifnull(t2.total_price, 0)) totalPrice,
sum(ifnull(t1.final_price, 0)) finalPrice, sum(ifnull(t2.final_price, 0)) finalPrice,
sum(ifnull(t1.total_price, 0) - ifnull(t1.final_price, 0)) as discountPrice sum(ifnull(t2.total_price, 0) - ifnull(t2.final_price, 0)) as discountPrice
from dj_car_life_goods_order t1 from dj_car_life_goods_order t1
inner join dj_car_life_goods_sub_order t2 on t1.order_code = t2.order_code inner join dj_car_life_goods_sub_order t2 on t1.order_code = t2.order_code
where t1.deleted_flag = 'N' and t2.deleted_flag = 'N' and t1.status = '4' where t1.deleted_flag = 'N' and t2.deleted_flag = 'N' and t1.status = '4'
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!