wokster/yii2-nested-sets-tree-behavior

NestedSetsTreeBehavior for build array from creocoder nested sets behavior and fancytree widget

Installs: 4 044

Dependents: 0

Suggesters: 0

Security: 0

Stars: 9

Watchers: 1

Forks: 3

Open Issues: 2

Type:yii2-extension

pkg:composer/wokster/yii2-nested-sets-tree-behavior

1.0 2017-07-27 17:03 UTC

This package is auto-updated.

Last update: 2025-09-29 01:55:50 UTC


README

NestedSetsTreeBehavior this is the connector between https://github.com/creocoder/yii2-nested-sets and https://github.com/wbraganca/yii2-fancytree-widget

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist wokster/yii2-nested-sets-tree-behavior "*"

or add

"wokster/yii2-nested-sets-tree-behavior": "*"

to the require section of your composer.json file.

Usage

Once the extension is installed, simply use it in your model :

'htmlTree'=>[
    'class' => \wokster\treebehavior\NestedSetsTreeBehavior::className()
]

use

SomeModel::findOne($id)->tree()

to get array for fancytree-widget