Skip to content

Latest commit

 

History

History
22 lines (18 loc) · 429 Bytes

README.md

File metadata and controls

22 lines (18 loc) · 429 Bytes

yii2-json-attribute-behavior

Yii2 Behavior for encode and decode json stored attributes

Instalation

composer require kfreiman/yii2-json-attribute-behavior "dev-master"

Use

public function behaviors()
{
    return [
        'jsonAttributes' => [
            'class' => JsonAttributeBehavior::className(),
            'attributes' => [
                'attrJson' => 'attr'
            ],
        ],
    ];
}