Skip to content
This repository was archived by the owner on Aug 1, 2024. It is now read-only.
This repository was archived by the owner on Aug 1, 2024. It is now read-only.

NumberRangeFilterType can not set attribute " type:'number' '' , and 'label' is not work as well #323

@CuteDeng

Description

@CuteDeng

In my project , I'm trying to use NumberRangeFilterType, but I found that a string value still can input to this form, and when I submit the form, the program throw an error => "No value found for key "left_number" in form data." So I try to set the following attribute, not work, can anyone tell me, what's the problem is ? thank you.

 ->add('age', NumberRangeFilterType::class, [
                'left_number_options'=>[
                    'label' => 'LABEL_FROM',
                    'attr' => [
                        'type' => 'number'
                    ]
                ],
                'right_number_options'=>[
                    'label'=>'LABEL_TO',
                    'attr' => [
                        'type' => 'number'
                    ]
                ],
               
            ])

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions