mirkhamidov / yii2-behavior-jsonfield
This package is abandoned and no longer maintained.
The author suggests using the m1roff/yii2-behavior-jsonfield package instead.
JSON field Behavior
2.1.0
2024-08-22 20:41 UTC
Requires
- php: ^8.0
Requires (Dev)
- codeception/codeception: ^4.0
- codeception/module-asserts: 2.0.x-dev
- codeception/module-db: ^2.0
- codeception/module-yii2: ^1.1
- friendsofphp/php-cs-fixer: ^3.10
- mockery/mockery: ^1.5
- spatie/phpunit-snapshot-assertions: ^4.2
- symfony/var-dumper: ^5.4
- yiisoft/yii2: dev-master
This package is auto-updated.
Last update: 2024-11-06 19:48:41 UTC
README
Installation
The preferred way to install this extension is through composer.
Either run
composer require mirkhamidov/yii2-behavior-jsonfield "dev-master"
Configure
add behavior entry to you model
/** @inheritdoc */ public function behaviors() { return ArrayHelper::merge(parent::behaviors(), [ 'interestsJson' => [ 'class' => JsonFieldBehavior::class, 'field' => 'interests', ], 'languagesJson' => [ 'class' => JsonFieldBehavior::class, 'field' => 'languages', ], ]); }