<?php

namespace Modules\ContactList\Exports;

use App\User;
use Maatwebsite\Excel\Concerns\FromCollection;
use Illuminate\Contracts\View\View;
use Maatwebsite\Excel\Concerns\FromView;
use Maatwebsite\Excel\Concerns\FromQuery;
use Maatwebsite\Excel\Concerns\Exportable;

class ContactListExport implements FromView
{
    /**
     * @return \Illuminate\Support\Collection
     */

    public function __construct($contact_lists,$user)
    {
        $this->contact_lists = $contact_lists;
        $this->user = $user;
    }


    public function view(): View
    {
        return view('admin.contact_lists.excel.contact_lists', [
            'contact_lists' => $this->contact_lists,
            'user' => $this->user
        ]);
    }
}
