bring into standalone plugin for distribution

This commit is contained in:
2024-11-24 18:38:29 -08:00
parent 279d46f14b
commit ded60d16bf
83 changed files with 7020 additions and 1 deletions

View File

@@ -0,0 +1,23 @@
<?php
namespace CakeProducts\Model\Enum;
use Cake\Database\Type\EnumLabelInterface;
use Tools\Model\Enum\EnumOptionsTrait;
enum ProductCategoryAttributeTypeId: int implements EnumLabelInterface
{
use EnumOptionsTrait;
case Constrained = 1;
case Text = 2;
case Integer = 3;
public function label(): string
{
return match($this) {
self::Constrained => 'Constrained',
self::Text => 'Text',
self::Integer => 'Integer'
};
}
}

View File

@@ -0,0 +1,23 @@
<?php
namespace CakeProducts\Model\Enum;
use Cake\Database\Type\EnumLabelInterface;
use Tools\Model\Enum\EnumOptionsTrait;
enum ProductProductTypeId: int implements EnumLabelInterface
{
use EnumOptionsTrait;
case Service = 1;
case Product = 2;
case Consumable = 3;
public function label(): string
{
return match($this) {
self::Service => 'Service',
self::Product => 'Product',
self::Consumable => 'Consumable'
};
}
}