diff --git a/api/app/Repositories/ProductsRepository.php b/api/app/Repositories/ProductsRepository.php index e4ec20e..e791e7a 100644 --- a/api/app/Repositories/ProductsRepository.php +++ b/api/app/Repositories/ProductsRepository.php @@ -17,7 +17,8 @@ class ProductsRepository implements ProductsRepositoryInterface { $query = Product::query(); if(isset($filters['search'])){ - $query->where('name', 'like', "${filters['search']}%"); + $search = ucfirst($filters['search']); + $query->where('name', 'like', "${search}%"); } return $query->paginate($filters['limit']);