[TYPO3-mvc] searching backward in model

Johannes C. Schulz - EnzephaloN IT-Solutions info at enzephalon.de
Tue Feb 7 08:39:00 CET 2012

The right way should be:
<f:for each="{accreditation.persons}" as="person" iteration="evenorodd">
<f:render partial="Accreditation/Persons"
<f:link.action action="makepdf"
pageUid="{pdfpage}" target="_blank">
public function makepdfAction(Tx_PsoaAccredit_Domain_Model_Person
$person,Tx_PsoaAccredit_Domain_Model_Accreditation $accreditation) {
But extbase says:
#1: PHP Catchable Fatal Error: Argument 2 passed to
Tx_PsoaAccredit_Controller_AccreditationController::makepdfAction() must be
an instance of Tx_PsoaAccredit_Domain_Model_Accreditation, none given in
ccreditationController.php line 197

I don't understand why the accreditation-object is empty, if it is submitted
to the action! In list and in partial its not empty!
Hope someone can help!

-----Ursprüngliche Nachricht-----
Von: typo3-project-typo3v4mvc-bounces at lists.typo3.org
[mailto:typo3-project-typo3v4mvc-bounces at lists.typo3.org] Im Auftrag von
Johannes C. Schulz - EnzephaloN IT-Solutions
Gesendet: Dienstag, 7. Februar 2012 07:31
An: 'TYPO3 v4 MVC project'
Betreff: [TYPO3-mvc] searching backward in model

Hello list!

I have a big problem, getting values of a parent-object.
I have a model called accreditation, that has (inline) childs called
Now I try to find the related accreditation of a person. I tried to
$this->accreditationRepository->findByUid($person->getAccreditation()); but
I got "Could not determine child object type". So I tried to write a
function returning just the accreditation-field, but I don't really know
how. The next try was to
$this->accreditationRepository->findByPersons($person); . But this returns

A fourth idea was, simply to transfer the accreditation-object from one
action to another. But it seems, that inside a person-related partial, the
accreditation-object isn't available, or?

Has anyone an idea, how to get the parent object from a childobject?

Best regards


TYPO3-project-typo3v4mvc mailing list
TYPO3-project-typo3v4mvc at lists.typo3.org

More information about the TYPO3-project-typo3v4mvc mailing list