<?php

namespace App\Exports;

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

class RecordsExport implements FromCollection,WithHeadings
{
    /**
    * @return \Illuminate\Support\Collection
    */
    public function collection()
    {
        return Record::select('id','first_name','second_name','midell_name','last_name',
        'roles_name','user_type','email','email_verified_at','dept_id',
        'phone','certificats','remember_token','deleted_at','created_at','updated_at','password'
        ,'password'
        )->get();
    }
}
