Project

General

Profile

Actions

Bug #65073

closed

SelectViewHelper doesn't handle optionValueField and optionLabelField for array options

Added by Alexander Schnitzler almost 10 years ago. Updated about 9 years ago.

Status:
Closed
Priority:
Should have
Category:
Fluid
Target version:
Start date:
2015-02-14
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
easy
Is Regression:
No
Sprint Focus:

Description

<f:form.select options="{array}" optionValueField="uid" optionLabelField="title" />

should work with the given array:
array(
    array(
        'uid' => 1,
        'title' => 'Foo'
    ),
    array(
        'uid' => -1,
        'title' => 'Bar'
    ),
    array(
        'title' => 'Baz'
    ),
    array(
        'uid' => '2'
    ),
)

Currently fluid tries to use the keys as values and the arrays as label which results in an error.

Actions

Also available in: Atom PDF