title: How can I pass parameter in the laravel excel?
body: <p>I get tutorial from here : <a href="https://laravel-excel.maatwebsite.nl/docs/3.0/export/basics" rel="noreferrer">https://laravel-excel.maatwebsite.nl/docs/3.0/export/basics</a></p>
  
  <pre><code>&lt;?php
  ...
  use App\Exports\ItemsDetailsExport;
  class ItemController extends Controller
  {
      ...
      public function exportToExcel(ItemsDetailsExport $exporter, $id)
      {
          //dd($id); I get the result
          return $exporter-&gt;download('Summary Detail.xlsx');
      }
  }
  </code></pre>
  
  <p>My export like this :</p>
  
  <pre><code>&lt;?php
  namespace App\Exports;
  use App\Repositories\Backend\ItemDetailRepository;
  use Maatwebsite\Excel\Concerns\FromCollection;
  use Maatwebsite\Excel\Concerns\Exportable;
  use Illuminate\Support\Facades\Input;
  class ItemsDetailsExport implements FromCollection
  {
      use Exportable;
      protected $itemDetailRepository;
      public function __construct(ItemDetailRepository $itemDetailRepository)
      {
          $this-&gt;itemDetailRepository = $itemDetailRepository;
      }
      public function collection()
      {
          $test  = Input::get('id');
          dd('yeah', $test);
      }
  }
  </code></pre>
  
  <p>I want to pass id parameter to export file. I try like that, but I don't get the id. The id is null</p>
  
  <p>How can I solve this problem?</p>