Hi!
Verwende Typo3 6.2.9 und die Extension dmmjobcontrol in der aktuellen Version. Leider kann ich nicht nach Kategorie oder Region/Ort suchen. Die Suche nach Stichwort liefert mir Ergebnisse. Bei Suche nach Kategorie oder Region/Ort (beides DropDown-Felder) liefert die Suche keine Ergebnisse.
Kann es sein, dass der Fehler in folgender Funktion liegt?:
function getFormSelect($field) { global $TCA; $session = $GLOBALS['TSFE']->fe_user->getKey('ses', $this->prefixId); if (isset($this->conf['multipleselect.'][$field]) && $this->conf['multipleselect.'][$field] != 1) { $multiple = ' multiple="multiple" size="'.$this->conf['multipleselect.'][$field].'"'; } else { $multiple = ''; } $return = '<select name="tx_dmmjobcontrol_pi1[search]['.$field.'][]" class="dmmjobcontrol_select dmmjobcontrol_'.$field.'"'.$multiple.'>'; if ($multiple == '') { $return .= '<option value="-1">'.$this->pi_getLL('form_select_text').'</option>'; } if (isset($TCA['tx_dmmjobcontrol_job']['columns'][$field]['config']['MM'])) { // The values for the select come from another table $whereAdd = 'pid IN ('.implode(',', $this->sysfolders).')'; $whereAddLang = ' AND sys_language_uid='.$GLOBALS['TSFE']->sys_language_content; $sort = $this->conf['sort.'][$field] ? $this->conf['sort.'][$field] : ($this->conf['property_sort'] ? $this->conf['property_sort'] : 'name ASC'); $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('uid, name', $TCA['tx_dmmjobcontrol_job']['columns'][$field]['config']['foreign_table'], $whereAdd.$whereAddLang, '', $sort); while($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) { $selected = ''; if (isset($session['search'][$field]) && in_array($row['uid'], $session['search'][$field])) { $selected = ' selected="selected"'; } $return .= '<option value="'.$row['uid'].'"'.$selected.'>'.$row['name'].'</option>'; } } elseif (is_array($TCA['tx_dmmjobcontrol_job']['columns'][$field]['config']['items'])) { // The values are in $TCA foreach ($TCA['tx_dmmjobcontrol_job']['columns'][$field]['config']['items'] AS $row) { $selected = ''; if (isset($session['search'][$field]) && in_array($row[1], $session['search'][$field])) { $selected = ' selected="selected"'; } $return .= '<option value="'.$row[1].'"'.$selected.'>'.$GLOBALS['TSFE']->sL($row[0]).'</option>'; } } $return .= '</select>'; if ($this->conf['show_icon'] && $selected == ' selected="selected"') { $return .= '<img class="dmmjobcontrol_selected_icon" src="typo3conf/ext/'.$this->extKey.'/icon_tx_dmmjobcontrol_arrow.gif" alt="" title="selected">'; } return $return; }
Oder an der übergeordneten Funktion?:
function getFormData() { $markerArray['###FORM_ATTRIBUTES###'] = ' action="'.$this->cachedLinkToPage($this->conf['pid.']['list']?$this->conf['pid.']['list']:$GLOBALS['TSFE']->id).'" method="post" '; $markerArray['###SECTOR_SELECT###'] = $this->getFormSelect('sector'); $markerArray['###REGION_SELECT###'] = $this->getFormSelect('region'); $markerArray['###CATEGORY_SELECT###'] = $this->getFormSelect('category'); $markerArray['###DISCIPLINE_SELECT###'] = $this->getFormSelect('discipline'); $markerArray['###EDUCATION_SELECT###'] = $this->getFormSelect('education'); $markerArray['###CONTRACT_TYPE_SELECT###'] = $this->getFormSelect('contract_type'); $markerArray['###JOB_TYPE_SELECT###'] = $this->getFormSelect('job_type'); $markerArray['###SEARCH_NAME###'] = 'tx_dmmjobcontrol_pi1[search_submit]'; $markerArray['###RESET_NAME###'] = 'tx_dmmjobcontrol_pi1[reset_submit]'; $markerArray['###KEYWORD_NAME###'] = 'tx_dmmjobcontrol_pi1[search][keyword]'; $session = $GLOBALS['TSFE']->fe_user->getKey('ses', $this->prefixId); $markerArray['###KEYWORD_VALUE###'] = htmlspecialchars($session['search']['keyword'], ENT_QUOTES); // Extend the markerArray with user function? if (isset($this->conf['searchArrayFunction']) && $this->conf['searchArrayFunction']) { $funcConf = $this->conf['searchArrayFunction.']; $funcConf['parent'] = & $this; $markerArray = $this->cObj->callUserFunction($this->conf['searchArrayFunction'], $funcConf, $markerArray); } return $markerArray; }
###KEYWORD_VALUE### funktioniert. ###CATEGORY_SELECT### z.B. nicht.
Danke für eure Hilfe!