behaviors\SluggableBehavior $slugAttribute

$slugAttribute public property The attribute that will receive the slug value public string $slugAttribute = 'slug'

behaviors\SluggableBehavior $immutable

$immutable public property (available since version 2.0.2) Whether to generate a new slug if it has already been generated before. If true, the behavior will not generate a new slug even if $attribute is changed. public boolean $immutable = false

behaviors\SluggableBehavior $ensureUnique

$ensureUnique public property Whether to ensure generated slug value to be unique among owner class records. If enabled behavior will validate slug uniqueness automatically. If validation fails it will attempt generating unique slug value from based one until success. public boolean $ensureUnique = false

behaviors\SluggableBehavior $attribute

$attribute public property The attribute or list of attributes whose value will be converted into a slug public string|array $attribute = null

behaviors\BlameableBehavior init()

init() public method Initializes the object. This method is invoked at the end of the constructor after the object is initialized with the given configuration. public void init ( )

behaviors\BlameableBehavior getValue()

getValue() protected method Returns the value for the current attributes. This method is called by evaluateAttributes(). Its return value will be assigned to the attributes corresponding to the triggering event. In case, when the $value property is null, the value of Yii::$app->user->id will be used as the value. protected mixed getValue ( $event )$event yii\base\Event The event that triggers the current attribute updating. return mixed The attribute value

behaviors\BlameableBehavior $value

$value public property The value that will be assigned to the current attributes. This can be an anonymous function, callable in array format (e.g. [$this, 'methodName']), an \yii\behaviors\Expression object representing a DB expression (e.g. new Expression('NOW()')), scalar, string or an arbitrary value. If the former, the return value of the function will be assigned to the attributes. The signature of the function should be as follows, function ($event) { // return value will be assi

behaviors\BlameableBehavior $updatedByAttribute

$updatedByAttribute public property The attribute that will receive current user ID value Set this property to false if you do not want to record the updater ID. public string $updatedByAttribute = 'updated_by'

behaviors\BlameableBehavior $createdByAttribute

$createdByAttribute public property The attribute that will receive current user ID value Set this property to false if you do not want to record the creator ID. public string $createdByAttribute = 'created_by'

behaviors\AttributeTypecastBehavior typecastValue()

typecastValue() protected method Casts the given value to the specified type. protected mixed typecastValue ( $value, $type )$value mixed Value to be type-casted. $type string|callable Type name or typecast callable. return mixed Typecast result.