Level 104
Is Exportable something from a package; where is that Builder being used after being returned from the datasource method?
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
i found this problem when exporting selected data, can someone help me? this is my code :
public function setUp(): array { $this->showCheckBox();
return [
Exportable::make('export')
->striped()
->type(Exportable::TYPE_XLS, Exportable::TYPE_CSV),
Header::make()->showSearchInput()->showToggleColumns(),
Footer::make()
->showPerPage()
->showRecordCount(),
];
}
public function datasource(): Builder
{
return Presence::query()
->where('attendance_id', $this->attendanceId)
->join('users', 'presences.user_id', '=', 'users.id')
->select('presences.*', 'users.name as user_name');
}
Please or to participate in this conversation.