Exemple #1
0
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_admin_allowed();
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'show') {
         return $this->Permission->is_allowed('view accounts chart');
     }
     return parent::isAuthorized($user);
 }
Exemple #3
0
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_allowed('view log');
     }
     if ($this->action === 'clear') {
         return $this->Permission->is_allowed('clear log');
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'add') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'edit') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'delete') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'profile') {
         return $this->Permission->is_registered_allowed();
     }
     if ($this->action === 'changepass') {
         return $this->Permission->is_registered_allowed();
     }
     if ($this->action === 'resetpass') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'first') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'account') {
         return $this->Permission->is_registered_allowed();
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'add') {
         return $this->Permission->is_allowed('add ledger');
     }
     if ($this->action === 'edit') {
         return $this->Permission->is_allowed('edit ledger');
     }
     if ($this->action === 'delete') {
         return $this->Permission->is_allowed('delete ledger');
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_allowed('view entry');
     }
     if ($this->action === 'show') {
         return $this->Permission->is_allowed('view entry');
     }
     if ($this->action === 'view') {
         return $this->Permission->is_allowed('view entry');
     }
     if ($this->action === 'add') {
         return $this->Permission->is_allowed('add entry');
     }
     if ($this->action === 'edit') {
         return $this->Permission->is_allowed('edit entry');
     }
     if ($this->action === 'delete') {
         return $this->Permission->is_allowed('delete entry');
     }
     if ($this->action === 'email') {
         return $this->Permission->is_allowed('view entry');
     }
     if ($this->action === 'download') {
         return $this->Permission->is_allowed('view entry');
     }
     if ($this->action === 'printpreview') {
         return $this->Permission->is_allowed('view entry');
     }
     if ($this->action === 'addrow') {
         if ($this->Permission->is_allowed('add entry') || $this->Permission->is_allowed('edit entry')) {
             return true;
         } else {
             return false;
         }
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_allowed('change account settings');
     }
     if ($this->action === 'account') {
         return $this->Permission->is_allowed('change account settings');
     }
     if ($this->action === 'cf') {
         return $this->Permission->is_allowed('cf account');
     }
     if ($this->action === 'email') {
         return $this->Permission->is_allowed('change account settings');
     }
     if ($this->action === 'printer') {
         return $this->Permission->is_allowed('change account settings');
     }
     if ($this->action === 'backup') {
         return $this->Permission->is_allowed('backup account');
     }
     if ($this->action === 'lock') {
         return $this->Permission->is_allowed('change account settings');
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'create') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'add') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'edit') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'update') {
         return $this->Permission->is_admin_allowed();
     }
     if ($this->action === 'delete') {
         return $this->Permission->is_admin_allowed();
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_allowed('access reports');
     }
     if ($this->action === 'balancesheet') {
         return $this->Permission->is_allowed('access reports');
     }
     if ($this->action === 'profitloss') {
         return $this->Permission->is_allowed('access reports');
     }
     if ($this->action === 'trialbalance') {
         return $this->Permission->is_allowed('access reports');
     }
     if ($this->action === 'ledgerstatement') {
         return $this->Permission->is_allowed('access reports');
     }
     if ($this->action === 'ledgerentries') {
         return $this->Permission->is_allowed('access reports');
     }
     if ($this->action === 'reconciliation') {
         return $this->Permission->is_allowed('access reports');
     }
     return parent::isAuthorized($user);
 }
 public function isAuthorized($user)
 {
     if ($this->action === 'index') {
         return $this->Permission->is_allowed('view entrytype');
     }
     if ($this->action === 'add') {
         return $this->Permission->is_allowed('add entrytype');
     }
     if ($this->action === 'edit') {
         return $this->Permission->is_allowed('edit entrytype');
     }
     if ($this->action === 'delete') {
         return $this->Permission->is_allowed('delete entrytype');
     }
     return parent::isAuthorized($user);
 }