zingimmick / laravel-scout-opensearch

Laravel Scout custom engine for OpenSearch
MIT License
19 stars 6 forks source link

Add option to match for strings #97

Closed Casmo closed 2 months ago

Casmo commented 2 months ago

For those interested: This PR adds that where(), whereIn() and whereNotIn() can have strings as values.

E.g.

$builder = Model::search()
   ->where('email', 'someone@example.com')
   ->whereIn('role', ['admin', 'user'])
   ->whereNotIn('uuid', ['00000-1111111-.....'])
   ->paginate();