541469799@qq.com 1 năm trước cách đây
mục cha
commit
bd6e4a3535
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  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');
     }
 
     /**