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.

25 satır
540B

  1. <?php
  2. namespace common\components;
  3. class Date
  4. {
  5. public static function getDaysOfWeekArray(): array
  6. {
  7. return [
  8. 1 => 'Lundi',
  9. 2 => 'Mardi',
  10. 3 => 'Mercredi',
  11. 4 => 'Jeudi',
  12. 5 => 'Vendredi',
  13. 6 => 'Samedi',
  14. 7 => 'Dimanche'
  15. ];
  16. }
  17. public static function getDayOfWeekStringByNumber(int $dayOfWeekNumber): string
  18. {
  19. $daysOfWeekArray = self::getDaysOfWeekArray();
  20. return $daysOfWeekArray[$dayOfWeekNumber];
  21. }
  22. }