Skip to content

Dynamic attributes for the product search model

Pre-release
Pre-release

Choose a tag to compare

@robotE13 robotE13 released this 26 Oct 01:48
· 12 commits to master since this release

Sample

In ProductController:

$searchModel = Yii::createObject([
    'class' => robote13\catalog\forms\ProductSearch,
    'productKind' => 'truck'
]);

Where 'productKind' this is robote13\catalog\models\ProductType::$table (table name for dynamic attributes of Product without prefix, it`s same that an alias for the product category)