Answers for "loading relationship inside relationship with laravel"

PHP
-1

laravel load relationship

use AppModelsBook;

$books = Book::all();

if ($someCondition) {
    $books->load('author', 'publisher');
}
Posted by: Guest on September-27-2021

Code answers related to "loading relationship inside relationship with laravel"

Browse Popular Code Answers by Language