hi019
11/20/2021, 4:42 AMJason Bosco
11/20/2021, 4:43 AMhi019
11/22/2021, 3:44 AMTypesense\Exceptions\ObjectNotFound
when trying to delete this model?
class Todo extends Model implements TypesenseSearch
{
use HasFactory, Searchable;
public function typesenseQueryBy(): array
{
return ['name'];
}
public function getCollectionSchema(): array {
return [
'name' => $this->searchableAs(),
'fields' => [
[
'name' => 'id',
'type' => 'string',
],
[
'name' => 'name',
'type' => 'string',
],
[
'name' => 'created_at',
'type' => 'int64',
],
],
'default_sorting_field' => 'created_at',
];
}
public function toSearchableArray()
{
return $this->toArray();
}
}
It’s in a new Laravel 8 project and the document is being indexed on create correctly. The error is being thrown here (where is $collectionIndex->getDocuments()->documents
being initialized?) https://github.com/devloopsnet/laravel-scout-typesense-engine/blob/50b60022605372b4b9eed0322d35335c9fd3d2e6/src/Typesense.php#L127Abdullah Al-Faqeir
11/22/2021, 4:15 PMhi019
11/22/2021, 10:02 PMhi019
11/22/2021, 10:02 PMAbdullah Al-Faqeir
11/23/2021, 12:09 AMJason Bosco
11/23/2021, 12:11 AMAbdullah Al-Faqeir
11/23/2021, 12:21 AM