← Back to plugin index

Date And Time Validator

Description

Validate a date and time.

  • If the date and time value was not specified, the corresponding error type is REQUIRED.
  • If the specified date and time is before the minimum, the corresponding error type is BEFORE_MIN_DATE.
  • If the specified date and time is after the maximum, the corresponding error type is AFTER_MAX_DATE.
Type name
DateAndTimeValidator
Class
com.airlock.iam.common.application.configuration.validation.DefaultDateAndTimeValidatorConfig
May be used by
Properties
Minimum Relative [days] (minRelative)
Description

The "minimum relative value" is the lower limit (earliest possible) for allowed difference in days to the current date.

Examples: A value of 1 means that tomorrow is the earliest possible date to enter, a value of -365 means that the entered date can be at most one year in the past.

Attributes
Integer
Optional
Min Date (minDate)
Description

The earliest date allowed to be filled in. This cannot be used together with "Minimum Relative" and must be in ISO 8601 format.

Attributes
String
Optional
Example
2011-12-03T10:15:30.000+01:00
Example
2018-02-06T15:58:53.661Z
Maximum Relative [days] (maxRelative)
Description

The "maximum relative value" is the upper limit (last possible) for allowed difference in days to the current date. This cannot be used together with "Max Date".

Examples: A value of 1 means that tomorrow is the latest possible date to enter, a value of -365 means that the entered date has to be at least one year in the past. Use this property to configure a minimal required age.

Attributes
Integer
Optional
Max Date (maxDate)
Description

The latest date allowed to be filled in. This cannot be used together with "Maximum Relative" and it must be in ISO 8601 format.

Attributes
String
Optional
Example
2011-12-03T10:15:30.000+01:00
Example
2018-02-06T15:58:53.661Z
YAML Template (with default values)

type: DateAndTimeValidator
id: DateAndTimeValidator-xxxxxx
displayName: 
comment: 
properties:
  maxDate:
  maxRelative:
  minDate:
  minRelative: