[TYPO3-mvc] Another shot : Problems with persisting updatedProperties of related models via Frontend Fluid Form - solved

Frank Gerards F.Gerards at esolut.de
Tue Nov 13 13:07:30 CET 2012


Solved it by allowing modifications of subobjects in the initializeAction of the controller

-----Ursprüngliche Nachricht-----
Von: typo3-project-typo3v4mvc-bounces at lists.typo3.org [mailto:typo3-project-typo3v4mvc-bounces at lists.typo3.org] Im Auftrag von Frank Gerards
Gesendet: Mittwoch, 7. November 2012 15:58
An: TYPO3-project-typo3v4mvc at lists.typo3.org
Betreff: [TYPO3-mvc] Another shot : Problems with persisting updatedProperties of related models via Frontend Fluid Form

Hi,

 

I render a frontend edit-Form to edit a model "offer", which has some "items" attached to it.

I loop over each item to get its properties as form-fields.

So the "name" of a item property form input field is:

 

1st item:

tx_myExt_myplugin[offer][item][<someSortOfHash>][myProp] 

 

2nd item:

tx_myExt_myplugin[offer][item][<someSortOdifferentfHash>][myProp] 

 

I see that each object in the lazyObjectStorage is of type Item and has a unique identifier.

When submitting this form, I get :

 

An error saying "array cannot be converted to plain value" using the old property mapper AND/OR

"Exception while property mapping at property path
"item.<someSortOfHash>": Creation of objects not allowed. To enable this, you need to set the PropertyMappingConfiguration Value "CONFIGURATION_CREATION_ALLOWED" to TRUE.

 

I digged into the extbase core code and found, that this exception is only thrown, if the incoming Request argument for

The typeConverter is an Array AND has no identity set.

 

So my question: What am I missing in my form ? I do all the form fields using f:form.textfield , for the items inside an f:for ViewHelper.

 

I hope someone can raise my PropertyMapper horizon a bit,

Thx in advance.

 

 

Frank

 

_______________________________________________
TYPO3-project-typo3v4mvc mailing list
TYPO3-project-typo3v4mvc at lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc


More information about the TYPO3-project-typo3v4mvc mailing list