Files

39 lines
790 B
PHP
Raw Permalink Normal View History

<?php
namespace App\Exports;
use App\Models\Phase;
use Maatwebsite\Excel\Concerns\FromCollection;
use Maatwebsite\Excel\Concerns\WithHeadings;
class PhasesExport implements FromCollection, WithHeadings
{
public function collection()
{
return Phase::select([
'id',
'project_id',
'name',
'progress_percent',
'start_date',
'end_date',
'created_at',
2026-08-28 13:04:28 +02:00
'updated_at',
])->get();
}
public function headings(): array
{
return [
'ID',
'ID Proyecto',
'Nombre',
'Progreso (%)',
'Fecha de inicio',
'Fecha de fin',
'Creado el',
2026-08-28 13:04:28 +02:00
'Actualizado el',
];
}
}