wesmiler hace 4 meses
padre
commit
7c04a1a40a
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      app/Services/Api/CartService.php

+ 1 - 0
app/Services/Api/CartService.php

@@ -100,6 +100,7 @@ class CartService extends BaseService
         }
 
         $model = $this->model->with(['store','cartGoods'])
+            ->withCount(['cartGoods'])
             ->from('carts as a')
             ->leftJoin('goods as b', 'b.id', '=', 'a.goods_id')
             ->where($where)