private function getRolesChain() {
        if (is_null($this->rolesChain)) {
            $chain = array();
            $role = $this->aclModel->getRoleById($this->roleId);
            while ($role != FALSE) {
                $chain[] = $role;
                $currId = $role['id_parent'];
                $role = $this->aclModel->getRoleById($currId);
            }

            $this->rolesChain = array_reverse($chain);
        }
        return $this->rolesChain;
    }
private function getRolesChain() {
        if (is_null($this->rolesChain)) {
            $chain = array();
            $role = $this->aclModel->getRoleById($this->roleId);
            while ($role != FALSE) {
                $chain[] = $role;
                $currId = $role['id_parent'];
                $role = $this->aclModel->getRoleById($currId);
            }

            $this->rolesChain = array_reverse($chain);
        }
        return $this->rolesChain;
    }
private function getRolesChain ( ) { if ( is_null ( $ this -> rolesChain ) ) { $ chain = array ( ) ; $ role = $ this -> aclModel -> getRoleById ( $ this -> roleId ) ; while ( $ role != FALSE ) { $ chain [ ] = $ role ; $ currId = $ role [ 'id_parent' ] ; $ role = $ this -> aclModel -> getRoleById ( $ currId ) ; } $ this -> rolesChain = array_reverse ( $ chain ) ; } return $ this -> rolesChain ; }
Get the list of roles chain. For example, if admin have user as parent
role, it returns the admin and user role.

@return array
Get the list of roles chain . For example if admin have user as parent role it returns the admin and user role .