541469799@qq.com hai 1 ano
pai
achega
bd6e4a3535
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      app/index/service/Cart.php

+ 2 - 1
app/index/service/Cart.php

@@ -68,9 +68,10 @@ class Cart extends BaseService
         if (empty($userId))return [];
 
         $model = new CartModel;
-        $model->where('user_id', '=', $userId)
+        $carts = $model->where('user_id', '=', $userId)
             ->where('is_delete', '=', 0)
             ->select();
+        return array_column($carts,'id');
     }
 
     /**