src/components/Auth.php
public function getPermissionTable($userId)
    {
        if ($this->_permissionTable === null) {
            $this->_permissionTable = (new Query())
                ->select(['*'])
                ->from('{{%admin_user_group}}')
                ->innerJoin('{{%admin_group_auth}}', '{{%admin_user_group}}.group_id={{%admin_group_auth}}.group_id')
                ->innerJoin('{{%admin_auth}}', '{{%admin_group_auth}}.auth_id = {{%admin_auth}}.id')
                ->where(['{{%admin_user_group}}.user_id' => $userId])
                ->all();
        }
        
        return $this->_permissionTable;
    }
public function getPermissionTable($userId)
    {
        if ($this->_permissionTable === null) {
            $this->_permissionTable = (new Query())
                ->select(['*'])
                ->from('{{%admin_user_group}}')
                ->innerJoin('{{%admin_group_auth}}', '{{%admin_user_group}}.group_id={{%admin_group_auth}}.group_id')
                ->innerJoin('{{%admin_auth}}', '{{%admin_group_auth}}.auth_id = {{%admin_auth}}.id')
                ->where(['{{%admin_user_group}}.user_id' => $userId])
                ->all();
        }
        
        return $this->_permissionTable;
    }
public function getPermissionTable ( $ userId ) { if ( $ this -> _permissionTable === null ) { $ this -> _permissionTable = ( new Query ( ) ) -> select ( [ '*' ] ) -> from ( '{{%admin_user_group}}' ) -> innerJoin ( '{{%admin_group_auth}}' , '{{%admin_user_group}}.group_id={{%admin_group_auth}}.group_id' ) -> innerJoin ( '{{%admin_auth}}' , '{{%admin_group_auth}}.auth_id = {{%admin_auth}}.id' ) -> where ( [ '{{%admin_user_group}}.user_id' => $ userId ] ) -> all ( ) ; } return $ this -> _permissionTable ; }
Get all permissions entries for the given User.

@param integer $userId The user id to retrieve the data for.
@return array
Get all permissions entries for the given User .