-
Notifications
You must be signed in to change notification settings - Fork 113
shouldBeSearchable not working? #84
Comments
Yeah, can confirm it dosen't work. Kinda hard to implement too. You can't create the fulltext index on only certain rows, all of it has go in there. The problem is you can't really filter them away after getting them from the db either, that causes trouble if you want to filter och limit the results :/ |
Having the same issue... |
I actually fixed the issue by setting the |
For those who need a workaround you can override the search method and manually tack on where clauses to the Builder instance:
Be aware of the limitations: https://laravel.com/docs/master/scout#where-clauses |
@freshleafmedia the workaround works fine as long as you don't want to do do something like I got around it by doing this:
another option is to simply add a callback when you do the ::search()
|
It seems that no matter what condition I set in shouldBeSearchable(), it doesn't matter. Example:
Even when approved is 0 for an item, it is still returned.
The text was updated successfully, but these errors were encountered: