2017 © Pedro Peláez
 

yii2-extension yii2-suffixtree-behavior

Behavior for use suffix tree

image

singrana/yii2-suffixtree-behavior

Behavior for use suffix tree

  • Tuesday, May 13, 2014
  • by Singrana
  • Repository
  • 2 Watchers
  • 0 Stars
  • 215 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 8 % Grown

The README.md

Suffix tree behavior

Behavior for use suffix tree. This behavior attached to your model for usage hierarchical structure., (*1)

Installation

The preferred way to install this extension is through composer., (*2)

Either run, (*3)

php composer.phar require --prefer-dist singrana/yii2-suffixtree-behavior "*"

or add, (*4)

"singrana/yii2-suffixtree-behavior": "*"

to the require section of your composer.json file., (*5)

Usage

Once the extension is installed, simply use it in your code by :, (*6)

Add in your model behaviors method:, (*7)

public function behaviors()
{
    return
    [
        ...

        'suffixTree'        =>
        [
            'class'         =>  'singrana\behaviors\SuffixBehavior',
        ],
        ...
    ];
}

You can configure behavior:, (*8)

  • fieldKey - attribute for storage suffix key;
  • fieldTranslit - attribute for storage translit, null if not need;
  • fieldUrl - attribute for storage Url, null if not need;
  • fieldParent - attribute for storage parent field, null if not need different trees storage;
  • fieldParentId - attribute for parent node Id;
  • fieldLevel - attribute for storage level node, null if not need;

The Versions

13/05 2014

dev-master

9999999-dev

Behavior for use suffix tree

  Sources   Download

MIT

by Avatar Singrana

extension yii2 behavior suffixtree