webui: Datetime parsing and formatting

this patch implements:
- output_formatter in field. It should be used in par with formatter. Formatter serves for datasource->widget conversion, output_formatter for widget->datasource format conversion.
- datetime module which parses/format strings in subset of ISO 8601 and LDAP generalized time format to Date.
- utc formatter replaced with new datetime formatter
- datetime_validator introduced
- new datetime field, extension of text field, which by default uses datetime formatter and validator

Dojo was regenerated to include dojo/string module

https://fedorahosted.org/freeipa/ticket/4194

Reviewed-By: Adam Misnyovszki <amisnyov@redhat.com>
This commit is contained in:
Petr Vobornik
2014-01-10 17:28:27 +01:00
committed by Petr Viktorin
parent 05f612e58a
commit 870a5daf24
14 changed files with 448 additions and 71 deletions

View File

@@ -695,6 +695,7 @@ class i18n_messages(Command):
"undo_all": _("undo all"),
"validation": {
"error": _("Text does not match field pattern"),
"datetime": _("Must be an UTC date/time value (e.g., \"2014-01-20 17:58:01Z\")"),
"decimal": _("Must be a decimal number"),
"integer": _("Must be an integer"),
"ip_address": _('Not a valid IP address'),