Project

General

Profile

Actions

Bug #57164

closed

NumberRangeValidator does not get options correctly

Added by Thomas Hucke about 10 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Extbase
Target version:
Start date:
2014-03-21
Due date:
% Done:

100%

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

Description

The validation always fails when I add the following annotation in my model * @validate NumberRange(minimum=1,maximum=999)

Adding DEBUG info to the NumberRangeValidator I see that $this->options[] does not get filled correctly. Only $this->options['minimum'] gets filled. $this->options['maximum'] is not set.

Unfortunately I don´t find the right place to check why the second option doesn´t get filled.
I see that something is weired there but I cannot go more into it - sorry :-(

BTW:
I´d been great if only one option could be mandatory because actually I´d like to check "Greater than" with only providing the 'minimum' option.


Files

AbstractValidator.patch (1.52 KB) AbstractValidator.patch Adds check on supportedOptions in constructor Thomas Hucke, 2014-03-22 13:18
AbstractValidator.patch (1.33 KB) AbstractValidator.patch Thomas Hucke, 2014-03-22 13:39
AbstractValidator.patch (1.37 KB) AbstractValidator.patch Thomas Hucke, 2014-03-22 15:26
AbstractValidator.patch (1.48 KB) AbstractValidator.patch Thomas Hucke, 2014-03-22 16:35
Actions

Also available in: Atom PDF