seach test

This commit is contained in:
merdan 2022-09-29 19:21:22 +05:00
parent e8cc285fa2
commit dab2fbc760
2 changed files with 7 additions and 5 deletions

View File

@ -51,8 +51,8 @@ class UpdateMeilisearchIndex extends Command
protected function updateSortableAttributes(Client $client):void protected function updateSortableAttributes(Client $client):void
{ {
$client->index('products_index')->updateSortableAttributes([ $client->index('products_index')->updateSortableAttributes([
'status', 'name',
'visible_individually', 'product_id',
]); ]);
$this->info('Updated sortable attributes...'); $this->info('Updated sortable attributes...');
@ -61,8 +61,9 @@ class UpdateMeilisearchIndex extends Command
protected function updateFilterableAttributes(Client $client): void protected function updateFilterableAttributes(Client $client): void
{ {
$client->index('products_index')->updateFilterableAttributes([ $client->index('products_index')->updateFilterableAttributes([
'name', 'status',
'product_id', 'visible_individually',
]); ]);
$this->info('Updated filterable attributes...'); $this->info('Updated filterable attributes...');

View File

@ -60,7 +60,8 @@ class ProductFlat extends Model implements ProductFlatContract
'name' => $this->name, 'name' => $this->name,
'meta_keywords' => $this->meta_keywords, 'meta_keywords' => $this->meta_keywords,
'status' => $this->status, 'status' => $this->status,
'visible_individually'=> $this->visible_individually 'visible_individually'=> $this->visible_individually,
'product_id' => $this->product_id
]; ];
} }
/** /**