liyinglin 2 years ago
parent 475d24c4a1
commit 1a918322c7

@ -446,7 +446,7 @@ class StatisticsController extends CommonController
public function lieToMoney($product_item_id, $factor_item_id, $orderIds)
{
$total = OrderItems::where('product_item_id', $product_item_id)
->whereJsonContains('factors->factor_item_id', "$factor_item_id")
->whereJsonContains('factors->factor_item_id', (string)$factor_item_id)
->whereIn('order_id', $orderIds)
->sum('total');
return $total;

Loading…
Cancel
Save