物料查询销量加上orderpay状态为1
This commit is contained in:
@@ -1201,10 +1201,11 @@ func GetMatterStoreOrderCount(ctx *jxcontext.Context, storeID int) (result *Orde
|
|||||||
WHERE IF(a.store_id = 0, a.jx_store_id, a.store_id) = 666666
|
WHERE IF(a.store_id = 0, a.jx_store_id, a.store_id) = 666666
|
||||||
AND a.from_store_id = ?
|
AND a.from_store_id = ?
|
||||||
AND a.status >= ? AND a.status <> ?
|
AND a.status >= ? AND a.status <> ?
|
||||||
|
AND b.status = ?
|
||||||
ORDER BY b.pay_finished_at DESC
|
ORDER BY b.pay_finished_at DESC
|
||||||
LIMIT 1
|
LIMIT 1
|
||||||
`
|
`
|
||||||
sqlParams := []interface{}{storeID, model.OrderStatusDelivering, model.OrderStatusCanceled}
|
sqlParams := []interface{}{storeID, model.OrderStatusDelivering, model.OrderStatusCanceled, model.PayStatusYes}
|
||||||
err = dao.GetRows(db, &orderPays, sql, sqlParams)
|
err = dao.GetRows(db, &orderPays, sql, sqlParams)
|
||||||
if len(orderPays) != 0 {
|
if len(orderPays) != 0 {
|
||||||
orderPay := orderPays[0]
|
orderPay := orderPays[0]
|
||||||
|
|||||||
Reference in New Issue
Block a user