Searchable is a trait for Laravel 4.2+ and Laravel 5.0 that adds a simple search function to Eloquent Models. Searchable allows you to perform searches in a table giving priorities to each field for the table and its relations. This is not optimized for big searches, but sometimes you just need to make it simple (Although it is not slow). By default, multi-word search terms are split and Searchable searches for each word individually. Relevance plays a role in prioritizing matches that match on multiple words. If you want to prioritize matches that include the multi-word search (thus, without splitting into words) you can enable full-text search by setting the third value to true.
Features
- Add the trait to your model and your search rules
- Documentation available
- Easy as laravel default queries
- Search method is compatible with any eloquent method
- Custom Threshold
- Entire Text search
Categories
FrameworksLicense
MIT LicenseFollow Laravel Searchable
You Might Also Like
Managing your therapy and rehab practice is a time-consuming process. You spend hours on paperwork, billing, scheduling, and more. Raintree’s Therapy & Rehab EHR is here to help you manage your practice more efficiently. With our all-in-one solution, you’ll get the tools you need to streamline your therapy and rehab practice, improve patient care, and get back to doing what you love.
Rate This Project
Login To Rate This Project
User Reviews
Be the first to post a review of Laravel Searchable!