From 1df696f5432a673a24ff5cb273fe068a7d88d6ea Mon Sep 17 00:00:00 2001 From: Tomas Babej Date: Thu, 9 Jan 2014 11:14:56 +0100 Subject: ipalib: Add DateTime parameter Adds a parameter that represents a DateTime format using datetime.datetime object from python's native datetime library. In the CLI, accepts one of the following formats: Accepts LDAP Generalized time without in the following format: '%Y%m%d%H%M%SZ' Accepts subset of values defined by ISO 8601: '%Y-%m-%dT%H:%M:%SZ' '%Y-%m-%dT%H:%MZ' '%Y-%m-%dZ' Also accepts above formats using ' ' (space) as a separator instead of 'T'. As a simplification, it does not deal with timezone info and ISO 8601 values with timezone info (+-hhmm) are rejected. Values are expected to be in the UTC timezone. Values are saved to LDAP as LDAP Generalized time values in the format '%Y%m%d%H%SZ' (no time fractions and UTC timezone is assumed). To avoid confusion, in addition to subset of ISO 8601 values, the LDAP generalized time in the format '%Y%m%d%H%M%SZ' is also accepted as an input (as this is the format user will see on the output). Part of: https://fedorahosted.org/freeipa/ticket/3306 Reviewed-By: Jan Cholasta --- ipalib/capabilities.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'ipalib/capabilities.py') diff --git a/ipalib/capabilities.py b/ipalib/capabilities.py index 3dd93294f..f2e45a0f6 100644 --- a/ipalib/capabilities.py +++ b/ipalib/capabilities.py @@ -48,6 +48,9 @@ capabilities = dict( # primary_key_types: Non-unicode primary keys in command output primary_key_types=u'2.83', + + # support for datetime values on the client + datetime_values=u'2.84' ) -- cgit