示例#1
0
 /**
  * Check - role is unremovable or not
  *
  * @param \XLite\Model\Role $role Role
  *
  * @return boolean
  */
 protected function isUnremovableRole(\XLite\Model\Role $role)
 {
     return $role->isPermanentRole() || \XLite\Core\Auth::getInstance()->getProfile()->GetRoles()->contains($role);
 }
示例#2
0
 /**
  * {@inheritDoc}
  */
 public function isPermanentRole()
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'isPermanentRole', array());
     return parent::isPermanentRole();
 }