Skip to content

vyants/yii2-softdelete

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Soft delete behavior for Yii2

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist vyants/yii2-softdelete "*"

or add

"vyants/yii2-softdelete": "*"

to the require section of your composer.json file.

Usage

public function behaviors() {
     return [
         'softDelete' => ['class' => 'vyants\softdelete\SoftDelete',
             'statusAttribute' => 'status',
             'timeAttribute' => false,
             'deletedValue' => -1,
             'activeValue' => 1,
         ],
     ];
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages