Commit 0e3bb0b23bcaa7a2f26d082249116887abe33584

Authored by Administrator
1 parent 56e665ef

big commti

common/modules/product/models/Export.php
@@ -31,7 +31,7 @@ class Export extends Model { @@ -31,7 +31,7 @@ class Export extends Model {
31 }*/ 31 }*/
32 $mods = []; 32 $mods = [];
33 33
34 - $filterString = $this->convertFilterToString($product->getFilters()); 34 + $filterString = $this->convertFilterToString($product->filters);
35 35
36 foreach ($product->variantsWithFilters as $variant) 36 foreach ($product->variantsWithFilters as $variant)
37 { 37 {
common/modules/product/models/Product.php
@@ -449,4 +449,10 @@ class Product extends \yii\db\ActiveRecord @@ -449,4 +449,10 @@ class Product extends \yii\db\ActiveRecord
449 $this->options = $values; 449 $this->options = $values;
450 } 450 }
451 451
  452 + public function getFilters(){
  453 +
  454 + return $this->hasMany(TaxOption::className(), ['tax_option_id' => 'option_id'])
  455 + ->viaTable('product_option',[ 'product_id'=> 'product_id'])
  456 + ->joinWith('taxGroup');
  457 + }
452 } 458 }