ldc-startcoq/app/Enums/Ingredients/IngredientFamilyEnum.php
Alexis Gousseau 95c9dd10d5 add enums
2023-02-23 10:26:11 +01:00

40 lines
1.3 KiB
PHP

<?php
namespace App\Enums\Ingredients;
enum IngredientFamilyEnum : int {
case alcool = 1;
case flavor = 2;
case naturalCasings = 3;
case groceryStore = 4;
case spicesHerbs = 5;
case flourBreadcrumbs = 6;
case fruitsVegetables = 7;
case aromaticMixMarinade = 8;
case functionalMixSimpleIngredients = 9;
case meatProducts = 10;
case sauces = 11;
case dairyProducts = 12;
public function label(): string {
return static::getLabel($this);
}
public static function getLabel(self $value): string {
return match ($value) {
self::alcool => __('Alcool'),
self::flavor => __('Arôme'),
self::naturalCasings => __('Boyaux Naturels'),
self::groceryStore => __('Épicerie'),
self::spicesHerbs => __('Épices et aromates'),
self::flourBreadcrumbs => __('Farine / Chapelure'),
self::fruitsVegetables => __('Fruits et légumes'),
self::aromaticMixMarinade => __('Mix aromatique / Marinade'),
self::functionalMixSimpleIngredients => __('Mix fonctionnel / ingredients simples'),
self::meatProducts => __('Produits carnés'),
self::sauces => __('Sauces'),
self::dairyProducts => __('Produits laitiers'),
};
}
}