Dashboard sipadu mbip
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

CompoundCurrentExport.php 701B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. namespace App\Exports;
  3. use App\Compound;
  4. use Maatwebsite\Excel\Concerns\Exportable;
  5. use Maatwebsite\Excel\Concerns\WithMultipleSheets;
  6. class CompoundCurrentExport implements WithMultipleSheets
  7. {
  8. use Exportable;
  9. private $data,$year1,$year2,$end_date;
  10. public function __construct($data,$year1,$year2,$end_date)
  11. {
  12. $this->data = $data;
  13. $this->year1 = $year1;
  14. $this->year2 = $year2;
  15. $this->end_date = $end_date;
  16. }
  17. /**
  18. * @return array
  19. */
  20. public function sheets(): array
  21. {
  22. $sheets = [];
  23. $sheets[] = new CompoundCurrentSheet($this->data, $this->year1, $this->year2, $this->end_date);
  24. return $sheets;
  25. }
  26. }