Hallo.
Ich soll neue Felder in tt_news, in den Namen aus tt_addresse angezeigt werden sollen.
Dafür mache ich so:
tca.php tt_news
'partner1' => array (
'exclude' => 1,
'label' => 'Partner 1',
'config' => array (
'type' => 'select',
'items' => Array (
array(
'',
0
),
),
'foreign_table' => 'tt_address',
'foreign_table_field' => 'name',
'foreign_table_where' => ' ORDER BY tt_address.name',
'size' => 1,
'minitems' => 0,
'maxitems' => 1,
)
),
'partner2' => array (
'exclude' => 1,
'label' => 'Partner 2',
'config' => array (
'type' => 'select',
'items' => Array (
array(
'',
0
),
),
'foreign_table' => 'tt_address',
'foreign_table_field' => 'name',
'foreign_table_where' => ' ORDER BY tt_address.name',
'size' => 1,
'minitems' => 0,
'maxitems' => 1,
)
),
'auftraggeber1' => array (
'exclude' => 1,
'label' => 'Auftraggeber 1',
'config' => array (
'type' => 'select',
'items' => Array (
array(
'',
0
),
),
'foreign_table' => 'tt_address',
'foreign_table_field' => 'name',
'foreign_table_where' => ' ORDER BY tt_address.name',
'size' => 1,
'minitems' => 0,
'maxitems' => 1,
)
),
'auftraggeber2' => array (
'exclude' => 1,
'label' => 'Auftraggeber 2',
'config' => array (
'type' => 'select',
'items' => Array (
array(
'',
0
),
),
'foreign_table' => 'tt_address',
'foreign_table_field' => 'name',
'foreign_table_where' => ' ORDER BY tt_address.name',
'size' => 1,
'minitems' => 0,
'maxitems' => 1,
)
),
in class.tx_tt_news.php
$markerArray['###PARTNER1###'] = $row['partner1'];
$markerArray['###PARTNER2###'] = $row['partner2'];
$markerArray['###AUFTRAGGEBER1###'] = $row['auftraggeber1'];
$markerArray['###AUFTRAGGEBER2###'] = $row['auftraggeber2'];
und in Template
###PARTNER1###
###PARTNER2###
###AUFTRAGGEBER1###
###AUFTRAGGEBER2###
auf der Seite, wo ich neue Nachricht erstellen kann, sehe ich 4 Felder mit Namen aus tt_addresse und kann die auswählen.
Auf der Web-Seite mit Single News sehe statt Namen nur die UID von tt_addresse.
Kann jemand mir sagen, wo der Fehler liegt?