From 485d402116a0cbf9cc435ad89d807df703e6f97e Mon Sep 17 00:00:00 2001 From: gazebo Date: Thu, 25 Jul 2019 10:10:36 +0800 Subject: [PATCH] =?UTF-8?q?-=20GetStoresOrderSaleInfo=E4=B8=AD=E7=9A=84?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E4=BB=8Eorder=5Fcreated=5Fat=E8=87=B3order?= =?UTF-8?q?=5Ffinished=5Fat?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- business/model/dao/dao_order.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/business/model/dao/dao_order.go b/business/model/dao/dao_order.go index 842e63bcf..ccb41cc44 100644 --- a/business/model/dao/dao_order.go +++ b/business/model/dao/dao_order.go @@ -140,7 +140,7 @@ func GetStoresOrderSaleInfo(db *DaoDB, storeIDList []int, fromTime time.Time, to CAST(SUM(IF(t1.earning_price <> 0, t1.earning_price, IF(t1.shop_price <> 0 && t1.shop_price < t1.sale_price, t1.shop_price, t1.sale_price) * IF(t5.pay_percentage > 0, t5.pay_percentage, %d) / 100)) AS SIGNED) earning_price FROM goods_order t1 LEFT JOIN store t5 ON t5.id = IF(t1.jx_store_id <> 0, t1.jx_store_id, t1.store_id) - WHERE t1.order_created_at >= ? AND t1.order_created_at <= ? + WHERE t1.order_finished_at >= ? AND t1.order_finished_at <= ? `, model.DefaultEarningPricePercentage) sqlParams := []interface{}{ model.OrderStatusEndBegin,