Commit ad0eb49ef8eadc52a9b6c81eae3b83801c8803ce
1 parent
02b8486e
add variantSku
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
models/Category.php
@@ -160,7 +160,7 @@ | @@ -160,7 +160,7 @@ | ||
160 | public function getProducts() | 160 | public function getProducts() |
161 | { | 161 | { |
162 | return $this->hasMany(Product::className(), [ 'id' => 'product_id' ]) | 162 | return $this->hasMany(Product::className(), [ 'id' => 'product_id' ]) |
163 | - ->viaTable('product_category', [ 'category_id' => 'id' ])->inverseOf('categories'); | 163 | + ->viaTable('product_category', [ 'category_id' => 'id' ]); |
164 | } | 164 | } |
165 | 165 | ||
166 | /** | 166 | /** |