Repository navigation
4.12.0
Added
- Search by a belongs to column:
// PostRepository
related() {
'user' => BelongsTo::make('user', 'user', UserRepository::class)->searchable([
'users.name'
])
}
So now your search will consider the users.name as well in a orWhere query:
?search=John Doe this will return you back all your posts where the belongs to user name has %John Doe%
Fixed
- Sorting by a belongs to column fixed. Before it was working only for the
namecolumn, now it's dynamical.