PHPackages                             soft-box/yii-permissions - 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. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. soft-box/yii-permissions

ActivePackage[Authentication &amp; Authorization](/categories/authentication)

soft-box/yii-permissions
========================

Yii permissions handler

1.0.1(3y ago)06MITPHPPHP ^7.0.0

Since Jun 27Pushed 3y ago1 watchersCompare

[ Source](https://github.com/Jarff/yii-permissions)[ Packagist](https://packagist.org/packages/soft-box/yii-permissions)[ RSS](/packages/soft-box-yii-permissions/feed)WikiDiscussions master Synced today

READMEChangelog (2)Dependencies (2)Versions (3)Used By (0)

INSTALATION
-----------

[](#instalation)

Run command php ./vendor/bin/console softbox:install. That will copy the necesary migrations

Then add the next function at your Funciones component. It should be located at: protected/components/Funciones.php

function can(String $permission){ //Buscamos al usuario $user = Users::model()-&gt;findByPk(Yii::app()-&gt;user-&gt;id); if($user){ return $user-&gt;can($permission); }else{ throw (new Exception("User not found")); } }

Add the Trait/HasRoles to your Users model

use Softbox\\YiiPermissions\\Traits\\HasRoles; /\*\*

- This is the model class for table "tbl\_users".
-
- The followings are the available columns in table 'tbl\_users':
- @property integer $id\_user
- @property integer $id\_type\_user
- @property integer $id\_customer
- @property string $alias\_user
- @property string $password\_user
- @property string $name\_user
- @property string $email\_user
- @property integer $status\_user
- @property string $date\_user\_load
- @property string $date\_low\_user
-
- The followings are the available model relations:
- @property Customers $idCustomer
- @property ReferenceGuides\[\] $referenceGuides \*/ class Users extends CActiveRecord { use HasRoles; ...

Run migrations to install tables

Add the next line to your protected/config/main.php file

...

'components' =&gt; \[ 'permisos'=&gt;array( 'class'=&gt;'Permissions', 'someconfig'=&gt;'someothervalue', ), \],

...

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

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 ~9 days

Total

2

Last Release

1459d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/de528c0ba6b451756fd294e7ae44a0859a77ce78322aadcfee902c84a6ea17b6?d=identicon)[rodsaseg](/maintainers/rodsaseg)

### Embed Badge

![Health badge](/badges/soft-box-yii-permissions/health.svg)

```
[![Health](https://phpackages.com/badges/soft-box-yii-permissions/health.svg)](https://phpackages.com/packages/soft-box-yii-permissions)
```

###  Alternatives

[simplesamlphp/simplesamlphp

A PHP implementation of a SAML 2.0 service provider and identity provider.

1.1k13.0M218](/packages/simplesamlphp-simplesamlphp)[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

103519.9k53](/packages/friendsoftypo3-content-blocks)[drupal/core

Drupal is an open source content management platform powering millions of websites and applications.

21866.0M1.7k](/packages/drupal-core)[api-platform/openapi

Models to build and serialize an OpenAPI specification.

404.8M94](/packages/api-platform-openapi)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M577](/packages/shopware-core)[bitrix24/b24phpsdk

An official PHP library for the Bitrix24 REST API

10244.2k5](/packages/bitrix24-b24phpsdk)

PHPackages © 2026

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