bariew/yii2-log-module Log management from web views

modulelog

Yii2 log module.

Description

Manages system logs from web views.

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist bariew/yii2-log-module "1.0.1"

or add

"bariew/yii2-log-module": "1.0.1"

to the require section of your composer.json file.

Usage

  • Add log component target and module in the main config components section:

    'components' => [
    ...
        'log' => [
            'targets' => [
                [
                    'class' => 'yii\log\DbTarget',
                    'levels' => ['error', 'warning'],
                    'logTable' => '{{%log_error}}',
                    'except' => [
                        'yii\web\HttpException:404',
                        'yii\web\HttpException:403',
                        'yii\web\HttpException:400',
                        'yii\i18n\PhpMessageSource::loadMessages'
                    ],
                ],
            ]
        ]
    ],
    'modules' => [
        ...
        'log' => [
            'class' => 'bariew\logModule\Module'
        ]
    ],
  • Apply migrations from the module migrations folder.

  • Go to log/error/index URL

Statistics

Downloads
GitHub Stars
GitHub Forks

Releases

Comments



1.0.2 is the latest of 3 releases



BSD-3-Clause license
Stats
4 github stars & 2 github forks
0 downloads in the last day
1 downloads in the last 30 days
346 total downloads