PHPackages                             cakebake/yii2-actionlog - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. cakebake/yii2-actionlog

AbandonedArchivedYii2-extension[Logging &amp; Monitoring](/categories/logging)

cakebake/yii2-actionlog
=======================

Logs user actions like create, read, update, delete and custom

v1.0.0-beta(11y ago)1711.6k8[2 PRs](https://github.com/cakebake/yii2-actionlog/pulls)LGPL-V3PHP

Since May 20Pushed 8y ago7 watchersCompare

[ Source](https://github.com/cakebake/yii2-actionlog)[ Packagist](https://packagist.org/packages/cakebake/yii2-actionlog)[ RSS](/packages/cakebake-yii2-actionlog/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

Yii2 Action Log
===============

[](#yii2-action-log)

Automatically logs user actions like create, update, delete. In addition, you can manually apply the method `ActionLog::add('Save sample message')`, where you will need.

Installation
------------

[](#installation)

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

Either run

```
php composer.phar require --prefer-dist cakebake/yii2-actionlog "*"

```

or add

```
"cakebake/yii2-actionlog": "*"

```

to the require section of your `composer.json` file.

Database Migration
------------------

[](#database-migration)

Check your database settings and run migration from your console:

```
php yii migrate --migrationPath=@vendor/cakebake/yii2-actionlog/migrations

```

For more informations see [Database Migration Documentation](http://www.yiiframework.com/doc-2.0/guide-console-migrate.html#applying-migrations)

Configuration
-------------

[](#configuration)

To access the module, you need to add this to your application configuration:

```
......
'modules' => [
    'actionlog' => [
        'class' => 'cakebake\actionlog\Module',
    ],
],
......

```

Add the new menu item to your navbar:

```
......
['label' => 'Log', 'url' => ['/actionlog/log/index']],
......

```

You may have to customize the user rights for the access log view. You could do it by editing `controllers/LogController.php`.

Example manual usage
--------------------

[](#example-manual-usage)

This is an example in the login method from the module cakebake/yii2-accounts.

```
use cakebake\actionlog\model\ActionLog;

......
public function login()
{
    $user = $this->getUser();
    if ($this->validate()) {
        ActionLog::add('success', $user->id); //log message for success

        return Yii::$app->user->login($user, $this->rememberMe ? 3600 * 24 * 30 : 0);
    } else {
        ActionLog::add('error', $user->id); //log message for error

        return false;
    }
}
......

```

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity32

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~4 days

Total

2

Last Release

4376d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3f0c610f1daae44aca882e9f8319422fc19d8fc9fa727051c005722c6eb8e5fe?d=identicon)[cakebake](/maintainers/cakebake)

---

Top Contributors

[![cakebake](https://avatars.githubusercontent.com/u/7462226?v=4)](https://github.com/cakebake "cakebake (34 commits)")

---

Tags

logyii2extensionactiverecordactionlog

### Embed Badge

![Health badge](/badges/cakebake-yii2-actionlog/health.svg)

```
[![Health](https://phpackages.com/badges/cakebake-yii2-actionlog/health.svg)](https://phpackages.com/packages/cakebake-yii2-actionlog)
```

###  Alternatives

[lav45/yii2-activity-logger

Tools to store user activity log for Yii2

3456.3k](/packages/lav45-yii2-activity-logger)[kriss/yii2-log-reader

Yii2 log reader

1340.1k1](/packages/kriss-yii2-log-reader)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
