選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

51 行
1.1KB

  1. <?php
  2. declare(strict_types=1);
  3. namespace App\ViewModels;
  4. class EmployeeFormViewModel
  5. {
  6. public string $title = 'Employee Directory';
  7. public string $eyebrow = 'SQLite employee form';
  8. public string $intro = 'Capture employee details in a lightweight SQLite-backed page that fits the framework style.';
  9. public bool $saved = false;
  10. public string $search = '';
  11. /**
  12. * @var array<string, string>
  13. */
  14. public array $form = [
  15. 'first_name' => '',
  16. 'last_name' => '',
  17. 'email' => '',
  18. 'department' => '',
  19. 'job_title' => '',
  20. 'start_date' => '',
  21. ];
  22. /**
  23. * @var array<string, list<string>>
  24. */
  25. public array $errors = [];
  26. /**
  27. * @var list<array<string, mixed>>
  28. */
  29. public array $employees = [];
  30. /**
  31. * @var array<string, int|string>
  32. */
  33. public array $summary = [
  34. 'employee_count' => 0,
  35. 'department_count' => 0,
  36. 'latest_start_date' => 'N/A',
  37. ];
  38. /**
  39. * @var array<string, mixed>|null
  40. */
  41. public ?array $newestEmployee = null;
  42. }

Powered by TurnKey Linux.