Hallo,
ich habe eine mn-Relation zwischen Person und Company im TCA erstellt.
Als Vorlage dient mir das IRRE-Tutorial:
wiki.typo3.org/Inline_Relational_Record_Editing_Attributes
Im Backend funktioniert alles wunderbar. Im Frontend bekomme ich aber eine
unknown Column Fehlermeldung, wenn ich mir alle Personen aus dem Repository
hole. Die SQL-Abfrage, die von Extbase generiert wird, ist falsch:
#1247602160: Unknown column 'tx_bbtestext_domain_model_company.person_id' in
'where clause'
SELECT tx_bbtestext_domain_model_company.* FROM tx_bbtestext_domain_model_company WHERE
tx_bbtestext_domain_model_company.person_id = 5 AND
tx_bbtestext_domain_model_company.deleted=0 AND
tx_bbtestext_domain_model_company.t3ver_state<=0 AND
tx_bbtestext_domain_model_company.pid<>-1 AND tx_bbtestext_domain_model_company.hidden=0
AND tx_bbtestext_domain_model_company.starttime<=1425298380 AND
(tx_bbtestext_domain_model_company.endtime=0 OR
tx_bbtestext_domain_model_company.endtime>1425298380)
Habe auch schon einen ähnliche Thread gefunden, leider nicht mit der passenden
Antwort. Hoffe ihr könnt mir weiterhelfen.
forum.typo3.org/index.php?t=msg&goto=480078
Hier die Auszüge aus meinen TCAs. Habe die Standard-Typo3-Felder weggelassen.
Wenn ihr die noch braucht, bitte Bescheid geben.
Person-TCA:
'companies' => array(
'exclude' => 1,
'label' => 'Companies',
"config" => Array (
"type" => "inline",
"foreign_table" => "tx_bbtestext_domain_model_relpersoncompany",
"foreign_field" => "person_id",
"foreign_selector" => "company_id",
"foreign_label" => "company_id",
"foreign_sortby" => "company_sort",
"maxitems" => 10,
'appearance' => array(
'showSynchronizationLink' => 1,
'showAllLocalizationLink' => 1,
'showPossibleLocalizationRecords' => 1,
'showRemovedLocalizationRecords' => 1,
),
'behaviour' => array(
'localizationMode' => 'select',
),
)
)
Company-TCA:
'personen' => array(
'exclude' => 1,
'label' => 'Persons',
"config" => Array (
"type" => "inline",
"foreign_table" => "tx_bbtestext_domain_model_relpersoncompany",
"foreign_field" => "company_id",
"foreign_selector" => "person_id",
"foreign_label" => "person_id",
"foreign_sortby" => "person_sort",
"maxitems" => 10,
'appearance' => array(
'showSynchronizationLink' => 1,
'showAllLocalizationLink' => 1,
'showPossibleLocalizationRecords' => 1,
'showRemovedLocalizationRecords' => 1,
),
'behaviour' => array(
'localizationMode' => 'select',
),
)
),
RelPersonCompany-TCA:
'person_id' => array(
"config" => Array (
"type" => "select",
"foreign_table" => "tx_bbtestext_domain_model_person",
"maxitems" => 1,
)
),
'company_id' => array(
"config" => Array (
"type" => "select",
"foreign_table" => "tx_bbtestext_domain_model_company",
"maxitems" => 1,
)
),
"person_sort" => Array (
"config" => Array (
"type" => "passthrough",
)
),
"company_sort" => Array (
"config" => Array (
"type" => "passthrough",
)
),
_______________________________________________
TYPO3-german mailing list
TYPO3-german@lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-german