<?php

namespace App\Exports\Activities\Two\Roshanaei;

use Maatwebsite\Excel\Concerns\WithMultipleSheets;
use App\Exports\Activities\Two\Roshanaei\Province;
use App\Exports\Activities\Two\Roshanaei\City;

class AllSheets implements WithMultipleSheets
{
    public function __construct($fromDate = null, $toDate = null, $province = null, $last_status_id = null)
    {
        $this->fromDate = $fromDate ?? null;
        $this->toDate = $toDate ?? null;
        $this->province = $province ?? null;
        $this->last_status_id = $last_status_id ?? null;
    }

    public function sheets(): array
    {
        return [
            0 => new Province($this->fromDate, $this->toDate, $this->province, $this->last_status_id),
            1 => new City($this->fromDate, $this->toDate, $this->province, $this->last_status_id)
        ];
    }
}
