/**
  * @see SearchAppController::index()
  */
 public function index()
 {
     if ($this->request->isPost()) {
         $this->_setSearchFields();
         $this->_searchParameters['canViewDraftOffices'] = 0;
         if ($this->OgAcl->canViewDraftOffices()) {
             $this->_searchParameters['canViewDraftOffices'] = 1;
         }
     }
     parent::index();
 }
 /**
  * @see SearchAppController::index()
  */
 public function index()
 {
     if ($this->request->isPost()) {
         $this->_setSearchFields();
         if ($this->OgAcl->canSearchForSuspendedUsers()) {
             $this->_searchParameters['includesuspendedusers'] = 1;
         }
         //for searching suspended users
         if ($this->OgAcl->canViewHrNote()) {
             $this->_searchParameters['omghrnote'] = '';
             $this->searchCategory[$this->_searchType]['fields']['omghrnote'] = 'HR Notes';
         }
         // adding HR notes as searchable field
     }
     parent::index();
 }
 /**
  * @see SearchAppController::index()
  */
 public function index()
 {
     if ($this->request->isPost()) {
         $this->_setSearchFields();
         if (!$this->OgAcl->canViewInactiveCompanies()) {
             $this->_operator = 'and';
             $this->_searchParameters['clientStatus'] = 837750;
         }
         //for searching inactive companies
         if (!$this->OgAcl->canViewCompanyPitchConsultants() && !$this->OgAcl->canViewCompanyProspects() && !$this->OgAcl->canViewCompanyInfluencers()) {
             $this->_operator = 'and';
             $this->_searchParameters['audienceType'] = 837767;
         }
         //
     }
     parent::index();
 }