add soft delete via muffin/trash to all product related tables
This commit is contained in:
@@ -14,6 +14,7 @@ use Cake\ORM\Entity;
|
||||
* @property string $product_catalog_id
|
||||
* @property DateTime $created
|
||||
* @property bool $enabled
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property ExternalProductCatalog $external_product_catalog
|
||||
* @property ProductCatalog $product_catalog
|
||||
@@ -34,6 +35,8 @@ class ExternalProductCatalogsProductCatalog extends Entity
|
||||
'product_catalog_id' => true,
|
||||
'created' => true,
|
||||
'enabled' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'external_product_catalog' => true,
|
||||
'product_catalog' => true,
|
||||
];
|
||||
|
||||
@@ -3,6 +3,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace CakeProducts\Model\Entity;
|
||||
|
||||
use Cake\I18n\DateTime;
|
||||
use Cake\ORM\Entity;
|
||||
|
||||
/**
|
||||
@@ -12,6 +13,7 @@ use Cake\ORM\Entity;
|
||||
* @property string $name
|
||||
* @property string $product_category_id
|
||||
* @property \CakeProducts\Model\Enum\ProductProductTypeId $product_type_id
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property \CakeProducts\Model\Entity\ProductCategory $product_category
|
||||
* @property \CakeProducts\Model\Entity\ProductAttribute[] $product_attributes
|
||||
@@ -31,7 +33,9 @@ class Product extends Entity
|
||||
'name' => true,
|
||||
'product_category_id' => true,
|
||||
'product_type_id' => true,
|
||||
'product_category' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'product_category' => false,
|
||||
'product_attributes' => true,
|
||||
];
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace CakeProducts\Model\Entity;
|
||||
|
||||
use Cake\I18n\DateTime;
|
||||
use Cake\ORM\Entity;
|
||||
|
||||
/**
|
||||
@@ -13,6 +14,7 @@ use Cake\ORM\Entity;
|
||||
* @property string $product_category_attribute_id
|
||||
* @property string|null $attribute_value
|
||||
* @property string|null $product_category_attribute_option_id
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property Product $product
|
||||
* @property ProductCategoryAttribute $product_category_attribute
|
||||
@@ -34,6 +36,8 @@ class ProductAttribute extends Entity
|
||||
'product_category_attribute_id' => true,
|
||||
'attribute_value' => true,
|
||||
'product_category_attribute_option_id' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'product' => false,
|
||||
'product_category_attribute' => false,
|
||||
'product_category_attribute_option' => false,
|
||||
|
||||
@@ -3,6 +3,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace CakeProducts\Model\Entity;
|
||||
|
||||
use Cake\I18n\DateTime;
|
||||
use Cake\ORM\Entity;
|
||||
|
||||
/**
|
||||
@@ -12,6 +13,7 @@ use Cake\ORM\Entity;
|
||||
* @property string $name
|
||||
* @property string|null $catalog_description
|
||||
* @property bool $enabled
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property ProductCategory[] $product_categories
|
||||
* @property ExternalProductCatalog[] $external_product_catalogs
|
||||
@@ -31,6 +33,8 @@ class ProductCatalog extends Entity
|
||||
'name' => true,
|
||||
'catalog_description' => true,
|
||||
'enabled' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'product_categories' => true,
|
||||
'external_product_catalogs' => true,
|
||||
];
|
||||
|
||||
@@ -3,6 +3,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace CakeProducts\Model\Entity;
|
||||
|
||||
use Cake\I18n\DateTime;
|
||||
use Cake\ORM\Entity;
|
||||
|
||||
/**
|
||||
@@ -17,6 +18,7 @@ use Cake\ORM\Entity;
|
||||
* @property int $lft
|
||||
* @property int $rght
|
||||
* @property bool $enabled
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property \CakeProducts\Model\Entity\ProductCatalog $product_catalog
|
||||
* @property \CakeProducts\Model\Entity\ParentProductCategory $parent_product_category
|
||||
@@ -42,6 +44,8 @@ class ProductCategory extends Entity
|
||||
'lft' => true,
|
||||
'rght' => true,
|
||||
'enabled' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'product_catalog' => true,
|
||||
'parent_product_category' => true,
|
||||
'child_product_categories' => true,
|
||||
|
||||
@@ -3,6 +3,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace CakeProducts\Model\Entity;
|
||||
|
||||
use Cake\I18n\DateTime;
|
||||
use Cake\ORM\Entity;
|
||||
|
||||
/**
|
||||
@@ -13,6 +14,7 @@ use Cake\ORM\Entity;
|
||||
* @property string|null $product_category_id
|
||||
* @property int $attribute_type_id
|
||||
* @property bool $enabled
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property ProductCategory $product_category
|
||||
* @property ProductCategoryAttributeOption[] $product_category_attribute_options
|
||||
@@ -33,6 +35,8 @@ class ProductCategoryAttribute extends Entity
|
||||
'product_category_id' => true,
|
||||
'attribute_type_id' => true,
|
||||
'enabled' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'product_category' => true,
|
||||
'product_category_attribute_options' => true,
|
||||
];
|
||||
|
||||
@@ -3,6 +3,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace CakeProducts\Model\Entity;
|
||||
|
||||
use Cake\I18n\DateTime;
|
||||
use Cake\ORM\Entity;
|
||||
|
||||
/**
|
||||
@@ -13,6 +14,7 @@ use Cake\ORM\Entity;
|
||||
* @property string $attribute_value
|
||||
* @property string $attribute_label
|
||||
* @property bool $enabled
|
||||
* @property DateTime|null $deleted
|
||||
*
|
||||
* @property ProductCategoryAttribute $product_category_attribute
|
||||
*/
|
||||
@@ -32,6 +34,8 @@ class ProductCategoryAttributeOption extends Entity
|
||||
'attribute_value' => true,
|
||||
'attribute_label' => true,
|
||||
'enabled' => true,
|
||||
'deleted' => true,
|
||||
// entities
|
||||
'product_category_attribute' => true,
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user