<?php

namespace App\Exports;

use App\Models\ContactUsModel;
use Maatwebsite\Excel\Concerns\FromCollection;
use Maatwebsite\Excel\Concerns\WithHeadings;

class ContactUsExport implements FromCollection,WithHeadings
{
    /**
    * @return \Illuminate\Support\Collection
    */
    public function collection()
    {
        return ContactUsModel::all();
    }

    public function headings(): array
    {
        return ['id', 'name','email', 'subject','message','created_at', 'updated_at'];
    }
}
