laravel / scout

Laravel Scout provides a driver based solution to searching your Eloquent models.
https://laravel.com/docs/scout
MIT License
1.54k stars 327 forks source link

Sort models after fetching when orders conditions are applied to search #849

Closed lubatti closed 1 month ago

lubatti commented 1 month ago

I've found that after applying a custom order logic to the search engine and retrieving a subset of ids, these ids can be re-sorted during the fetching of the models.

crynobone commented 1 month ago

This is only supported by MySQL and SQLite and will cause syntax error in Postgres and MSSQL

taylorotwell commented 1 month ago

Thanks for your pull request to Laravel!

Unfortunately, I'm going to delay merging this code for now. To preserve our ability to adequately maintain the framework, we need to be very careful regarding the amount of code we include.

If applicable, please consider releasing your code as a package so that the community can still take advantage of your contributions!