Checkbox checked when Object has multiple values from a m:n related table
Hello Dev Team,
the checkboxViewHelper lacks of support set the checkboxes being checked when the formObject has properties referenced through ObjectStorage Instances.
I found the \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFieldViewHelper::getPropertyValue() being responsible for that.
I included my fix of the function getPropertyValue() as an suggestion inside the attached file.
Works for me, hope this helps to improve Fluid.
#2 Updated by Claus Due about 5 years ago
- Status changed from New to Resolved
Positive that this one is no longer an issue: ObjectAccess::getPropertyPath is since then fitted with special support for accessing exactly ObjectStorage using numerical indices and AbstractFormFieldViewHelper does passthrough to ObjectAccess::getPropertyPath (see also: #66533). CheckboxViewHelper itself converts iterators to arrays and is able to resolve nested properties using dotted paths (including numerical indices in ObjectStorage). Whichever commit(s) introduced those simply did not include this issue in the list of solved/referenced issues.
If I'm wrong don't hesitate to ask for this to be reopened!