Export fails, even though I am exporting the exact same columns from the tables.
The table code
the exporter code
->columns([
TextColumn::make('scans.0.scan_time')->label('Entry Time'),
TextColumn::make('last_scan_time')->label('Exit Time'),
TextColumn::make('ronde.site.name')->label('Site'),
TextColumn::make('user.employee.first_name')->label('Employee Name'),
TextColumn::make('user.employee.supervisor.first_name')->label('Supervisor Name'),
TextColumn::make('ronde.typeDeRonde.label')->label('Ronde type'),
->columns([
TextColumn::make('scans.0.scan_time')->label('Entry Time'),
TextColumn::make('last_scan_time')->label('Exit Time'),
TextColumn::make('ronde.site.name')->label('Site'),
TextColumn::make('user.employee.first_name')->label('Employee Name'),
TextColumn::make('user.employee.supervisor.first_name')->label('Supervisor Name'),
TextColumn::make('ronde.typeDeRonde.label')->label('Ronde type'),
return [
ExportColumn::make('id')
->label('ID'),
ExportColumn::make('ronde.site.name')->label('Site'),
ExportColumn::make('created_at')->label('Date'),
ExportColumn::make('user.employee.first_name')->label('Employee Name'),
ExportColumn::make('scans.0.scan_time')->label('Entry Time'),
ExportColumn::make('last_scan_time')->label('Exit Time'),
ExportColumn::make('user.employee.supervisor.first_name')->label('Supervisor Name'),
ExportColumn::make('ronde.typeDeRonde.label')->label('Ronde type'),
return [
ExportColumn::make('id')
->label('ID'),
ExportColumn::make('ronde.site.name')->label('Site'),
ExportColumn::make('created_at')->label('Date'),
ExportColumn::make('user.employee.first_name')->label('Employee Name'),
ExportColumn::make('scans.0.scan_time')->label('Entry Time'),
ExportColumn::make('last_scan_time')->label('Exit Time'),
ExportColumn::make('user.employee.supervisor.first_name')->label('Supervisor Name'),
ExportColumn::make('ronde.typeDeRonde.label')->label('Ronde type'),
1 Reply
Solution
Nothing wrong in the code. Just clear cache and job tables.