WebUI: Add positive number validator

Add new validator which inherits from integer validator
and checks whether the integer is positive.

https://pagure.io/freeipa/issue/6980

Reviewed-By: Felipe Volpone <felipevolpone@gmail.com>
This commit is contained in:
Pavel Vomacka
2017-07-11 10:46:36 +02:00
committed by Martin Babinsky
parent 7f10a5145c
commit 3cac851498
2 changed files with 44 additions and 0 deletions

View File

@@ -982,6 +982,7 @@ class i18n_messages(Command):
"min_value": _("Minimum value is ${value}"),
"net_address": _("Not a valid network address (examples: 2001:db8::/64, 192.0.2.0/24)"),
"parse": _("Parse error"),
"positive_number": _("Must be a positive number"),
"port": _("'${port}' is not a valid port"),
"required": _("Required field"),
"unsupported": _("Unsupported value"),