Bug #61099

CheckboxViewhelper and Objects

Added by Tobias H. about 6 years ago. Updated about 2 years ago.

Should have
Target version:
Start date:
Due date:
% Done:


TYPO3 Version:
PHP Version:
Is Regression:
Sprint Focus:


Hi there,

i have a filter object for a fluid form. In there i have objects i would like to use with checkboxes:

            <f:for each="{colors}" as="color" >
                <label for="size">{color.name}</label>
                 <f:form.checkbox property="colors" value="{color.uid}"/>

This will only work with the attached patch to the CheckboxViewhelper.php in Fluid. Without the checkboxes are not correctly checked again. The objects are all correct in my filter model. The following code with the same model is working:

<f:form.select property="colors" options="{colors}" optionLabelField="name" multiple="1" />

What is wrong? Can someone help me? I found this workaround: http://www.muenster-webdesign.net/blog/typo3-mit-fluid-und-dem-checkbox-viewhelper-mehrere-objekte-einer-klasse-erzeugen/

But i think the Viewhelper can handle objects, why not in my case?

Best Regards,

CheckboxViewHelper.patch View - Patch (708 Bytes) Tobias H., 2014-08-20 16:13

CheckboxViewHelper.patch View - Patch No.2 (921 Bytes) Tobias H., 2014-08-21 09:17

CheckboxViewHelper.patch View - Patch without debug (764 Bytes) Tobias H., 2014-08-21 09:20

Related issues

Related to TYPO3 Core - Bug #64057: Checkbox viewhelper checked attribute not set for objects Closed 2014-12-30
Related to TYPO3 Core - Feature #62436: Checkbox checked when Object has multiple values from a m:n related table Closed 2014-10-23


#2 Updated by Tobias H. about 6 years ago

first patch not working. Please consider that the patch is not working with normal arrays for checkboxes.

#4 Updated by Claus Due about 5 years ago

  • Status changed from New to Accepted

I think your example would actually work if you switched from "property" to using "name" and manually prefixing the field name with the object name. However, that's a workaround, and there's no reason why this should not be fixed in CheckboxViewHelper.

Patch is reviewed and should work. Please either create a merge request or ask for assistance in creating one!

#5 Updated by Claus Due about 5 years ago

  • Status changed from Accepted to Resolved

I revise my earlier statement after having investigated #62436 - this issue would be almost identical to the one reported there, and multiple fixes have been applied to fix each individual problem case related to checkboxes with objects as values and the "checked" property. Like #62436, this one is already resolved.

#6 Updated by Benni Mack about 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF