/** * Returns a text element for autosearch. Can be overruled. * * The form / html elements to search on. Elements can be grouped by inserting null's between them. * That creates a distinct group of elements * * @param \MUtil_Model_ModelAbstract $model * @param array $data The $form field values (can be usefull, but no need to set them) * @return array Of \Zend_Form_Element's or static tekst to add to the html or null for group breaks. */ protected function getAutoSearchElements(\MUtil_Model_ModelAbstract $model, array $data) { $elements = parent::getAutoSearchElements($model, $data); if ($model->isMultiOrganization()) { $options = $this->currentUser->getRespondentOrganizations(); $elements[] = $this->_createSelectElement(\MUtil_Model::REQUEST_ID2, $options, $this->_('(all organizations)')); } return $elements; }