base commit

This commit is contained in:
Mekan1206
2026-07-30 17:24:40 +05:00
commit a794dacd39
345 changed files with 29597 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
<?php
declare(strict_types=1);
namespace App\Imports;
use Illuminate\Support\Collection;
use Maatwebsite\Excel\Concerns\ToCollection;
use Maatwebsite\Excel\Concerns\WithHeadingRow;
class EmployeesImport implements ToCollection, WithHeadingRow
{
/** @var Collection<int, array<string, mixed>> */
private Collection $rows;
public function __construct()
{
$this->rows = collect();
}
public function collection(Collection $rows): void
{
$this->rows = $rows->map(
fn (Collection $row): array => $row->toArray(),
);
}
/**
* @return Collection<int, array<string, mixed>>
*/
public function getRows(): Collection
{
return $this->rows;
}
}