Skip to content

Commit

Permalink
Add more regions
Browse files Browse the repository at this point in the history
  • Loading branch information
Tschucki committed Mar 3, 2024
1 parent 4f870e5 commit b36406f
Showing 1 changed file with 48 additions and 1 deletion.
49 changes: 48 additions & 1 deletion app/Enums/Region.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,59 @@
enum Region: string implements HasLabel
{
case BAVARIA = 'bavaria';
case BADENWUERTTEMBERG = 'Baden-Württemberg';
case BERLIN = 'Berlin';
case BRANDENBURG = 'Brandenburg';
case BREMEN = 'Bremen';
case HAMBURG = 'Hamburg';
case HESSEN = 'Hessen';
case MECKLENBURGVORPOMMEN = 'Mecklenburg-Vorpommern';
case NIEDERSACHSEN = 'Niedersachsen';
case NORDRHEINWESTFALEN = 'Nordrhein-Westfalen';
case RHEINLANDPFALZ = 'Rheinland-Pfalz';
case SAARLAND = 'Saarland';
case SACHSEN = 'Sachsen';
case SACHSENANHALT = 'Sachsen-Anhalt';
case SCHLEWSIGHOLSTEIN = 'Schleswig-Holstein';
case THUERINGEN = 'Thüringen';
case BURGENLAND = 'Burgenland';
case KAERNTEN = 'Kärnten';
case NIEDEROESTERREICH = 'Niederösterreich';
case OBEROESTERREICH = 'Oberösterreich';
case SALZBURG = 'Salzburg';
case STEIERMARK = 'Steiermark';
case TIROL = 'Tirol';
case VORARLBERG = 'Vorarlberg';
case WIEN = 'Wien';

public function getLabel(): ?string
{
return match ($this) {
self::BAVARIA => 'Bayern',
// TODO: Add Regions
self::BADENWUERTTEMBERG => 'Baden-Württemberg',
self::BERLIN => 'Berlin',
self::BRANDENBURG => 'Brandenburg',
self::BREMEN => 'Bremen',
self::HAMBURG => 'Hamburg',
self::HESSEN => 'Hessen',
self::MECKLENBURGVORPOMMEN => 'Mecklenburg-Vorpommern',
self::NIEDERSACHSEN => 'Niedersachsen',
self::NORDRHEINWESTFALEN => 'Nordrhein-Westfalen',
self::RHEINLANDPFALZ => 'Rheinland-Pfalz',
self::SAARLAND => 'Saarland',
self::SACHSEN => 'Sachsen',
self::SACHSENANHALT => 'Sachsen-Anhalt',
self::SCHLEWSIGHOLSTEIN => 'Schleswig-Holstein',
self::THUERINGEN => 'Thüringen',
self::BURGENLAND => 'Burgenland',
self::KAERNTEN => 'Kärnten',
self::NIEDEROESTERREICH => 'Niederösterreich',
self::OBEROESTERREICH => 'Oberösterreich',
self::SALZBURG => 'Salzburg',
self::STEIERMARK => 'Steiermark',
self::TIROL => 'Tirol',
self::VORARLBERG => 'Vorarlberg',
self::WIEN => 'Wien',
};
}
}

0 comments on commit b36406f

Please sign in to comment.