Skip to content

nemozar/yii2-action-log

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

yii2-action-log

Extension logged all request for controllers. Saved in database url, post data, user, referrer. There is a form for viewing and searching logs.

Config modules in web.php.

userModel - model for show user name in report.

modelUserName - field in model with user name.

Enabled - if set false logs will be not saved in database.

'logs' => [
    'class' => 'nemozar\yii2ActionLog\Module',
    'userModel' => \komeks\yii2User\models\User::class,
    'modelUserName' => 'username',
    'enabled' => true
]

Up migrations

./yii migrate --migrationPath=@yii/rbac/migrations/ 

For saved logs add trair for need controllers:

class RatingController extends Controller
{
    use LogsTrait;

    ...
}

Url for form show /logs/log/index

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages