22 lines
597 B
PHP
22 lines
597 B
PHP
|
<?php
|
||
|
namespace App\Services\Search;
|
||
|
|
||
|
use ScoutElastic\IndexConfigurator;
|
||
|
|
||
|
class BookConfigurator extends IndexConfigurator
|
||
|
{
|
||
|
// It's not obligatory to determine name. By default it'll be a snaked class name without `IndexConfigurator` part.
|
||
|
protected $name = 'books';
|
||
|
|
||
|
// You can specify any settings you want, for example, analyzers.
|
||
|
protected $settings = [
|
||
|
'analysis' => [
|
||
|
'analyzer' => [
|
||
|
'es_std' => [
|
||
|
'type' => 'standard',
|
||
|
'stopwords' => '_spanish_'
|
||
|
]
|
||
|
]
|
||
|
]
|
||
|
];
|
||
|
}
|