Commit 5e07d411 authored by Ad Schellevis's avatar Ad Schellevis

(mvc) swap validation order in AutoNumberField

parent feae22dd
...@@ -130,11 +130,11 @@ class AutoNumberField extends BaseField ...@@ -130,11 +130,11 @@ class AutoNumberField extends BaseField
$validators = parent::getValidators(); $validators = parent::getValidators();
if ($this->internalValue != null) { if ($this->internalValue != null) {
$validators[] = new IntegerValidator(array('message' => $this->internalValidationMessage));
$validators[] = new MinMaxValidator(array('message' => $this->internalValidationMessage, $validators[] = new MinMaxValidator(array('message' => $this->internalValidationMessage,
"min" => $this->minimum_value, "min" => $this->minimum_value,
"max" => $this->maximum_value "max" => $this->maximum_value
)); ));
$validators[] = new IntegerValidator(array('message' => $this->internalValidationMessage));
} }
return $validators; return $validators;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment