Project

General

Profile

Actions

Bug #97028

closed

Validators not removed when variant applies

Added by Helmut Hummel over 2 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Form Framework
Target version:
-
Start date:
2022-02-24
Due date:
% Done:

0%

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

Description

Given state

Given there is a form element definition, that has two validators configured and a variant definition that matches and overrides the validators.

Expectation

all validators are removed and new variant validators are applied

Actual

only the first validator is removed and the variant validators are added on top

Verified with TYPO3 11

Example form to reproduce

type: Form
identifier: testformWizardElements
label: 'Testform'
prototypeName: standard
renderingOptions:
    submitButtonLabel: Submit
renderables:
    -   type: Page
        identifier: page-1
        label: Step
        renderingOptions:
            previousButtonLabel: 'Previous step'
            nextButtonLabel: 'Next step'
        renderables:
            -   type: Text
                identifier: text-3
                label: Text3
                defaultValue: '1234567'
                validators:
                    -   identifier: Integer
                    -   identifier: StringLength
                        options:
                            minimum: '1'
                            maximum: '6'
                variants:
                    -   identifier: 'text-3-change-validator'
                        condition: '1 === 1'
                        validators:
                            -   identifier: Integer
                            -   identifier: StringLength
                                options:
                                    minimum: '2'
                                    maximum: '9'


Related issues 1 (0 open1 closed)

Is duplicate of TYPO3 Core - Bug #96424: Resetting form validators does not work as expectedClosed2021-12-21

Actions
Actions

Also available in: Atom PDF