28. Query Scopes In Laravel Eloquent | Laravel 9 Full Course

Опубликовано: 29 Сентябрь 2024
на канале: AR Shahin
49
1

28. Query Scopes In Laravel Eloquent | Query Scopes
Global scopes allow you to add constraints to all queries for a given model. Laravel's own soft delete functionality utilizes global scopes to only retrieve "non-deleted" models from the database. Writing your own global scopes can provide a convenient, easy way to make sure every query for a given model receives certain constraints.
#laravel
#laravelcourse