[TYPO3-german] TCA: optionales Select-Feld

Ralf-Rene Schröder ralf.rene at online.de
Wed Oct 16 16:59:37 CEST 2013


Am 16.10.2013 16:44, schrieb Marc Wöhlken:
> Freue mich über Lösungsansätze
ich habe in einem Projekt zwei von einander abhängige Selectboxen
account und entry
ich sehe auf den ersten Blick keinen Unterschied zu dir
(natürlich gibt es nach der account Wahl ein Reload des BE-forms)
das TCA ist folgendes (hoffe es hilft):

'account' => array (		
	'exclude' => 0,		
	'label' =>
'LLL:EXT:if_cwmedia/locallang_db.xml:tx_ifcwmedia_mediaitems.account',		
	'config' => array (
		'type' => 'select',	
		'items' => array (
			array('',0),
		),
		'foreign_table' => 'fe_users',	
		'foreign_table_where' => 'ORDER BY fe_users.username',	
		'size' => 1,	
		'minitems' => 0,
		'maxitems' => 1,
	)
),
'entry' => array (		
	'exclude' => 0,		
	'label' =>
'LLL:EXT:if_cwmedia/locallang_db.xml:tx_ifcwmedia_mediaitems.entry',		
	'config' => array (
		'type' => 'select',	
		'items' => array (
			array('',0),
		),
		'foreign_table' => 'tx_ifcatalog_entry',	
		'foreign_table_where' => 'AND tx_ifcatalog_entry.hidden=0 AND
tx_ifcatalog_entry.account=###REC_FIELD_account### ORDER BY
tx_ifcatalog_entry.title',	
		'size' => 1,	
		'minitems' => 0,
		'maxitems' => 1,
	)
),


-- 
image[FORMAT] - Ralf-René Schröder
http://www.image-format.eu ... Wir geben Ihrem Image das richtige Format


More information about the TYPO3-german mailing list