pantera-digital/yii2-user-balance

There is no license information available for the latest version (dev-master) of this package.

dev-master 2019-08-30 10:30 UTC

This package is auto-updated.

Last update: 2025-03-01 00:23:52 UTC


README

User balance module for Yii2 apps

Install

Run

php composer require pantera-digital/yii2-user-balance "*"

Or add to composer.json

"pantera-digital/yii2-user-balance": "*",

and execute:

php composer update

Migrations:

php yii migrate --migrationPath=vendor/pantera-digital/yii2-user-balance/migrations

Usage

Add below lines to 'components' section:

'userBalance' => [
    'class' => \pantera\user\balance\Component::class,
    'userModel' => 'path-to-your-user-module\models\User',
],

And add this to 'modules' section:

'user-balance' => [
    'class' => \pantera\user\balance\Module::class,
    'access' => ['admin'], // by default 'access' => ['@']
]