From a2f887c764c3aae410ddcc87d82f42e980f7bfe9 Mon Sep 17 00:00:00 2001 From: merdan Date: Sat, 16 Apr 2022 20:42:55 +0500 Subject: [PATCH] search suggestions start --- packages/Sarga/API/Http/Controllers/Products.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/Sarga/API/Http/Controllers/Products.php b/packages/Sarga/API/Http/Controllers/Products.php index a416a4e70..bf3d3f7e9 100644 --- a/packages/Sarga/API/Http/Controllers/Products.php +++ b/packages/Sarga/API/Http/Controllers/Products.php @@ -129,7 +129,7 @@ class Products extends ProductController ->where('status',1) ->where('name','like','%' . urldecode($key) . '%') ->orderBy('name','asc') - ->limit(10) + ->take(10) ->get('id','name'); // $products = $this->productRepository->searchProductByAttribute($key); @@ -143,7 +143,7 @@ class Products extends ProductController ->where('channel', $channel) ->where('locale', $locale) ->orderBy('product_id', 'desc') - ->limit(10) + ->take(10) ->get('product_id','name'); return $products->merge($brands);