Relation not loading #792
-
ButtonGroupColumn::make('Actions')
->attributes(function($row) {
return [
'class' => 'space-x-4 flex',
];
})
->buttons([
LinkColumn::make('Carrier')
->title(fn($row) => svg('heroicon-o-eye', 'h-5 w-5 text-gray-600'))
->location(fn($row) => route('careers.show', $row->carrier->id)),
LinkColumn::make('Carrier phone')
->title(fn($row) => svg('heroicon-o-phone-outgoing', 'h-5 w-5 text-green-500'))
->location(fn($row) => 'tel:+1'.str_replace(['(', ')', ' ', '-'], '', $row->carrier->phone)),
]), public function builder(): Builder
{
return Calls::query()
->join(
table: 'entity',
first: 'calls.career_id',
operator: '=',
second: 'entity.id'
)
->agreed()
->selfResponsible();
} But it has a relation. How to make this work? |
Beta Was this translation helpful? Give feedback.
Answered by
rubensrocha
Apr 7, 2025
Replies: 1 comment
-
I resolved this situation using the $this->setAdditionalSelects() setting.
|
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
lrljoe
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I resolved this situation using the $this->setAdditionalSelects() setting.