velletti / ke_questionnaire

This is a fork of the offical ke_questionnaire, compatible with TYPO3 - 8.7. LTS
1 stars 3 forks source link

The argument answer was registered with type MatrixRow, but is of type MatrixHeader #2

Closed tobiasschaeferptb closed 5 years ago

tobiasschaeferptb commented 5 years ago

If I use the answer type Matrix header it leads to this exception: The argument "answer" was registered with type "Kennziffer\KeQuestionnaire\Domain\Model\AnswerType\MatrixRow", but is of type "Kennziffer\KeQuestionnaire\Domain\Model\AnswerType\MatrixHeader"

velletti commented 5 years ago

I do not have a working example in V 6.x using matrix or matrix header (l used this type last time 6 Years Ago and forgot how i worked then) the viewhelper itself looks strange to me as it is used in the partial martixRow and matrixHeader with the same argument 'answer' that will explain the error message. But inside of the renderFunction the agrument type matrixrow is not renderd: only matrixHeader and extendedMatrixHeader

But maybe cahngeing the viewhelper: www/http/typo3conf/ext/ke_questionnaire/Classes/ViewHelpers/MatrixRowViewHelper.php

with the code below helps .. if yes, i can check it in ..

`<?php namespace Kennziffer\KeQuestionnaire\ViewHelpers; /***

/* *

velletti commented 5 years ago

okay, found it: the type should be 'mixed'

see latest version