[TYPO3-mvc] Complex array validation

Jacob Rasmussen jacob at lightbulb.dk
Tue Feb 7 17:03:24 CET 2012

Hi again,
> Is {newInquiry} a proper object? For example, if the initial value is NULL you should do:
> if ($newInquiry === NULL) {
>      $newInquiry = $this->objectManager->create($modelClassName);
> }
> ...in the controller action. This is a limitation unfortunately - the fed:form.group VH does not work unless it has a proper object instance to work on.

It wasn't - so I've added the above lines to the controller action.
But... now I get a new exception from the cache handler - and before I 
do some serious debugging, I'd like to hear if you have any simple 

#1233058486: "" is not a valid cache entry identifier

The stacktrace looks a bit like this:

67 t3lib_cache_frontend_AbstractFrontend::has("")
66 Tx_Extbase_Object_Container_ClassInfoCache::has("")
65 Tx_Extbase_Object_Container_Container::getClassInfo("")
64 Tx_Extbase_Object_Container_Container::getInstanceInternal("", array)
63 Tx_Extbase_Object_Container_Container::getInstance("", array)
62 Tx_Extbase_Object_ObjectManager::get("")
61 Tx_Fed_ViewHelpers_Form_GroupViewHelper::render()

It seems that the GroupViewHelper tries to instantiate an empty class 
name, so could it be because of some kind of missing annotation 
(although I've created my models through the extension builder - so it 
should be in order).

My fluid template now looks like this:

<f:form class="clearfix" method="post" action="create" 
enctype="multipart/form-data"  name="newInquiry" object="{newInquiry}">
   <fed:form.group amount="1" property="{newInquiry.oensker}" 
     <f:form.textfield property="{property.fraDato.name}" 
class="calendar" />
     <f:form.textfield property="{property.tilDato.name}" 
class="calendar" />

Where newInquiry.oensker is the objectStorage property and fraDato and 
tilDato are properties on the sub model.

Kind regards

Jacob Rasmussen
Certified TYPO3 Integrator

More information about the TYPO3-project-typo3v4mvc mailing list