Open CnczubehoerEu opened 4 years ago
I’m using Neos Flow 6.0.6. I would like to use the optionValueField-tag in my select-field.
<f:form.select property=“blubb” options="{blub}" optionValueField=“price” />
When “getPrice()” returns a double value, the select form shows only one option and the value of the option is “1”. In my case, the double value was “1.36”. So, the “1” could be a rounded value.
When I’m using the function
getOptionValue() { return (string)$this->price; }
and
<f:form.select property=“blubb” options="{blub}" optionValueField=“optionValue” />
everything is fine.
getPrice() { return 1.234; }
A select field with 1.234 as option value.
A select field with 1 as option value.
Neos:
Flow: 6.0.6
You can get this information by running composer show.
composer show
The code where the is_float case is missing is https://github.com/neos/flow-development-collection/blob/5.3/Neos.FluidAdaptor/Classes/ViewHelpers/Form/SelectViewHelper.php#L240-L254
is_float
Description
I’m using Neos Flow 6.0.6. I would like to use the optionValueField-tag in my select-field.
When “getPrice()” returns a double value, the select form shows only one option and the value of the option is “1”. In my case, the double value was “1.36”. So, the “1” could be a rounded value.
When I’m using the function
and
everything is fine.
Steps to Reproduce
getPrice() { return 1.234; }
Expected behavior
A select field with 1.234 as option value.
Actual behavior
A select field with 1 as option value.
Affected Versions
Neos:
Flow: 6.0.6
You can get this information by running
composer show
.