Bug #37543

Additional __identity field when using TYPO3.Media

Added by Michel Albers about 3 years ago. Updated almost 2 years ago.

Status:Closed Start date:2012-05-28
Priority:Must have Due date:
Assigned To:Bastian Waidelich % Done:

0%

Category:ViewHelpers
Target version:TYPO3 Flow Base Distribution - 1.1.1 Estimated time:0.50 hour
Has patch:No Affected Flow version:FLOW3 1.1.0 beta 1

Description

When using a <f:form.upload /> field for uploading a TYPO3.Media Image, FLUID adds a hidden _identity field for the Image which results in an "_identity mapping is not allowed" exception when saving the record. Removing the hidden __identity field by deleting

$content .= $this->renderAdditionalIdentityFields();

from FormViewHelper.php on line 127 solves the particular problem. Some further if / else conditions are needed.

History

#1 Updated by Michel Albers about 3 years ago

  • Assigned To deleted (Robert Lemke)

#2 Updated by Sebastian Kurfuerst about 3 years ago

  • Status changed from New to Accepted
  • Assigned To set to Sebastian Kurfuerst

I'll take care of that; the solution you proposed is just a workaround unfortunately.

#3 Updated by Karsten Dambekalns about 3 years ago

  • Target version changed from 1.1 beta 2 to 1.1 RC1

#4 Updated by Karsten Dambekalns about 3 years ago

  • Target version changed from 1.1 RC1 to 1.1

#5 Updated by Bastian Waidelich about 3 years ago

  • Status changed from Accepted to Needs Feedback
  • Assigned To changed from Sebastian Kurfuerst to Bastian Waidelich

This should be fixed with https://review.typo3.org/#/c/12221/

Can you please confirm?

#6 Updated by Karsten Dambekalns about 3 years ago

I just wrote Michel an email asking again for feedback.

#7 Updated by Michel Albers about 3 years ago

Thanks! I'll check on that this evening!

#8 Updated by Michel Albers about 3 years ago

Still getting the error "it's not allowed to map property __identity" when submitting the upload form with a previously set value. Sorry :/

#9 Updated by Martin Keck about 3 years ago

Two remarks from my point of view (using 1.1 rc2 and TYPO3.Media) to probably make things clearer:
1. The problem only emerges when editing/updating an existing content (or whatever element) having a TYPO3.Media image as property (i. e. in newly created form there's no _identity hidden field for the image created)
2. I can confirm Michel's comment, that the suggested patch does not change anything (it's already part of rc2). The hidden field's still there, e. g. <input type="hidden" name="content[image][
_identity]" value="11db8fa6-71ad-4f89-a0d3-e75c4c545412" />. Removing it from the HTML output before submitting the form leads to a correctly updated image.

#10 Updated by Karsten Dambekalns almost 3 years ago

  • Target version changed from 1.1 to 1.1.1

#11 Updated by Karsten Dambekalns over 2 years ago

  • Target version changed from 1.1.1 to 2052

#13 Updated by Bastian Waidelich about 2 years ago

  • Status changed from Needs Feedback to Closed

Thanks for the feedback (I lost track of this one)

#14 Updated by Karsten Dambekalns almost 2 years ago

  • Target version changed from 2052 to 1.1.1

Also available in: Atom PDF