fix sku variant values association on variants table

git st
This commit is contained in:
2025-10-07 01:16:13 -07:00
parent e9ba1845ba
commit 44130c0cd2
2 changed files with 6 additions and 4 deletions

View File

@@ -62,9 +62,11 @@ class ProductVariantsTable extends Table
'joinType' => 'INNER',
]);
$this->hasMany('ProductCategoryVariantOptions', [
'className' => 'CakeProducts.Products',
'foreignKey' => 'product_category_variant_id',
$this->hasMany('ProductSkuVariantValues', [
'className' => 'CakeProducts.ProductSkuVariantValues',
'foreignKey' => 'product_variant_id',
'dependent' => true,
'cascadeCallbacks' => true,
]);
}