Exemplo n.º 1
1
 function process()
 {
     if (!is_admin($GLOBALS['current_user']) && in_array($this->action, $this->admin_actions)) {
         $this->hasAccess = false;
     }
     parent::process();
 }
Exemplo n.º 2
0
 public function process()
 {
     if (!is_admin($GLOBALS['current_user'])) {
         $this->hasAccess = false;
     }
     parent::process();
 }
Exemplo n.º 3
0
 public function process()
 {
     if (!is_admin($GLOBALS['current_user']) && !is_admin_for_module($GLOBALS['current_user'], 'Contracts')) {
         $this->hasAccess = false;
     }
     parent::process();
 }
 public function testprocess()
 {
     $SugarController = new SugarController();
     //execute the method and check if it works and doesn't throws an exception
     try {
         $SugarController->process();
     } catch (Exception $e) {
         $this->fail();
     }
     $this->assertTrue(true);
 }
Exemplo n.º 5
0
 public function process()
 {
     global $app_list_strings;
     $app_list_strings['report_available_modules'] = Reports_Utils::available_modules(FALSE);
     foreach ($app_list_strings['report_available_modules'] as $key => &$val) {
         if (isset($app_list_strings['moduleList'][$key])) {
             $val = $app_list_strings['moduleList'][$key];
         }
     }
     parent::process();
 }
Exemplo n.º 6
0
 function process()
 {
     $GLOBALS['log']->info(get_class($this) . ":");
     global $current_user;
     $access = get_admin_modules_for_user($current_user);
     if (is_admin($current_user) || is_admin_for_any_module($current_user) && !isset($_REQUEST['view_module']) && (isset($_REQUEST['action']) && $_REQUEST['action'] != 'package') || isset($_REQUEST['view_module']) && (in_array($_REQUEST['view_module'], $access) || empty($_REQUEST['view_module'])) || isset($_REQUEST['type']) && ($_REQUEST['type'] == 'dropdowns' && is_admin_for_any_module($current_user) || $_REQUEST['type'] == 'studio' && displayStudioForCurrentUser() == true)) {
         $this->hasAccess = true;
     } else {
         $this->hasAccess = false;
     }
     parent::process();
 }
Exemplo n.º 7
0
 function process()
 {
     $GLOBALS['log']->info(get_class($this) . ":");
     global $current_user;
     $access = $current_user->getDeveloperModules();
     if ($current_user->isAdmin() || $current_user->isDeveloperForAnyModule() && !isset($_REQUEST['view_module']) && (isset($_REQUEST['action']) && $_REQUEST['action'] != 'package') || isset($_REQUEST['view_module']) && (in_array($_REQUEST['view_module'], $access) || empty($_REQUEST['view_module'])) || isset($_REQUEST['type']) && ($_REQUEST['type'] == 'dropdowns' && $current_user->isDeveloperForAnyModule() || $_REQUEST['type'] == 'studio' && displayStudioForCurrentUser() == true)) {
         $this->hasAccess = true;
     } else {
         $this->hasAccess = false;
     }
     parent::process();
 }
 function process()
 {
     if (isset($_REQUEST['searchFormTab']) && $_REQUEST['searchFormTab'] == 'basic_search') {
         $this->modifySearch('subject_basic');
         $this->modifySearch('description_basic');
     } else {
         if (isset($_REQUEST['searchFormTab']) && $_REQUEST['searchFormTab'] == 'advanced_search') {
             $this->modifySearch('name_advanced');
             $this->modifySearch('description_advanced');
         }
     }
     parent::process();
 }
Exemplo n.º 9
0
 function process()
 {
     $GLOBALS['log']->info(get_class($this) . ":");
     global $current_user;
     $access = get_admin_modules_for_user($current_user);
     //Non admins can still execute functions
     if (!empty($_REQUEST['action']) && in_array($_REQUEST['action'], $this->non_admin_actions) || $this->isModuleAdmin($access)) {
         $this->hasAccess = true;
     } else {
         $this->hasAccess = false;
     }
     parent::process();
 }
Exemplo n.º 10
0
 public function process()
 {
     if ($this->action == 'EditView' && empty($_REQUEST['record'])) {
         $this->action = 'WizardHome';
     } else {
         if ($this->action == 'EditView' && !empty($_REQUEST['record'])) {
             // Show Send Email and Summary
             $this->action = 'WizardHome';
             // modules/Campaigns/WizardHome.php isWizardSummary
             $_REQUEST['action'] = 'WizardHome';
         }
     }
     parent::process();
 }
Exemplo n.º 11
0
 public function process() {
     if($this->action == 'EditView' && empty($_REQUEST['record'])) {
         $this->action = 'WizardHome';
     }
     parent::process();
 }