Questions tagged [laravel-scout]

A Laravel package that provides a simple, driver based solution for adding full-text search to models.

Laravel Scout provides a simple, driver based solution for adding full-text search to Laravel's Eloquent models. Using model observers, Scout will automatically keep your search indexes in sync with your Eloquent records.

Documentation is available at https://laravel.com/docs/5.4/scout

This is not a package which is included in the default installation of Laravel so it needs to be installed independently.

225 questions
0
votes
0 answers

Inceasing hitsPerPage in search request (Meilisearch)

Using Meilisearch for the first time in my web app and it's working great except that queries give 20 hits tops where I should get 100+. So I read the docs and hitsPerPage seems to be the option to increase. But I'm struggling with the syntax to…
Rome
  • 432
  • 6
  • 27
0
votes
0 answers

Complex relational search using Laravel Scout (Meilisearch driver) - Laravel

Summary I'm new to Laravel scout and Meilisearch, I'm building a CRM application with Laravel, there already a index method I have that returns paginated data after fetching from database. However the query is very dynamic, I mean it depends on many…
Aniket Das
  • 367
  • 1
  • 6
  • 17
0
votes
0 answers

Working with Scout and elasticsearch engine with babenkoivan/elastic-scout-driver-plus and factories

I am quite comfortable working with the babenkoivan/elastic-scout-driver-plus driver and Elasticsearch. However to date for the subject of the tests I have used my own approach instead of using the factories because I am unable to configure it…
abkrim
  • 3,512
  • 7
  • 43
  • 69
0
votes
1 answer

Elasticsearch query multidimensional array values

I have these mappings: 'indices' => [ 'mappings' => [ 'default' => [ 'properties' => [ 'id' => [ 'type' => 'keyword', ], 'name' => [ …
rst630
  • 59
  • 2
  • 14
0
votes
1 answer

Exclude models with criteria from Scout

My User model has a nullable column name. I never want to import users, that have no name. I tried public function toSearchableArray() { if (!$this->name) { return [ 'name' => $this->name, 'email' =>…
JanBoehmer
  • 395
  • 3
  • 14
0
votes
1 answer

How to test Laravel Scout adds data to indexes and search results match properly?

I'm trying to test my Laravel Scout (Mellisearch) with PestPHP. Testing the model data gets sent to the search index and the search is correct. For the search, if I were to search user $user = User::search('wanna_coder101')->get();, then it'd return…
wanna_coder101
  • 508
  • 5
  • 19
0
votes
0 answers

'loosen up' Laravel Scout's search functionality to return more results with database driver

I'm using Laravel Scout with the driver set as database to create a searchable knowlegde base. The issue i've currently got it that I would like each word in the search term to be searched for an return all results that have any of the words rather…
0
votes
0 answers

How do I filter certain column using Laravel Scout

Products table id name commercial_name category_id 1 Pro1 Pro Com1 1 2 Pro2 Pro Com2 2 Categories table id name 1 Cat 1 2 Cat 2 What I am trying to do I am using Meilisearch with Laravel Scout and I am trying to make the…
Jaad
  • 89
  • 1
  • 6
0
votes
1 answer

Laravel Meilisearch using non-case sensitive filters

I am trying to search and filter using Meilisearch and Laravel Scout. Database Table Sample: ` id name code 1 Panadol 123 2 Cometrex 456 3 Panadol 789 ` Data From Frontend: query = pana (It is a string for search and it will search…
0
votes
0 answers

Using Laravel Scout database driver, where does it store the indexes?

I was trying out Laravel Scout's database driver and I am wondering how it works behind the scene. Where does it store the indices and how does it perform the searches?
r2b2
  • 1,255
  • 5
  • 13
  • 34
0
votes
1 answer

Laravel Scout check if index exists

I can't find documentation on how to check with Laravel Scout if an index exists or not. I'm using it with meilisearch. My models have the Searchable trait. This is how I want to access the index and check for search results: $tasks = Task::search( …
Fabian
  • 1,806
  • 5
  • 25
  • 40
0
votes
0 answers

Custom Laravel Scout transformer for Algolia

I've gotten my model data into Algolia by using having a large transformation occur in my model. I'd like to move this into a custom transformer now as I refactor. Algolia has this article…
Steven Grant
  • 1,236
  • 3
  • 15
  • 32
0
votes
0 answers

Scout Import Meilisearch with UUID doesn't import records

My blog table has the following structure Schema::create('blogs', function (Blueprint $table) { $table->uuid('id')->primary(); And my scout is configured with Meilisearch as driver. When I issue the import command php artisan scout:import…
0
votes
1 answer

Security API in meilisearch

I want to know if it is completly neccesary to use a security KEY in meilisearch. I´m building an app in laravel, its like a blog, where I have the users and the posts with its comments. My searcher its similar to the stack overflow, where we can…
0
votes
2 answers

Laravel Scout search by multiple columns

I have a user model with the following fields: protected $fillable = [ 'name', 'email', 'password', 'birthday', 'surname' ]; I created a search bar to search the users. I'm using Laravel scout to query the users like…
Nil Suria
  • 474
  • 4
  • 15