Exemplo n.º 1
0
 protected function _preDispatch($action)
 {
     parent::_preDispatch($action);
     if (!SimplePortal_Static::hasPermission('useCreateNew')) {
         return $this->responseNoPermission();
     }
 }
Exemplo n.º 2
0
 protected function _preDispatch($action)
 {
     parent::_preDispatch($action);
     if (!SimplePortal_Static::getItemModel()->canPromoteItem(null, array())) {
         throw $this->getNoPermissionResponseException();
     }
 }