Validation Messages¶
Validation messages provides plugin developers capability to provide custom validation error messages for user inputs
in Delphix Engine UI. Validation messages
helps user better understand the input requirements and provide the input
that matches the plugin developers requirements.
Data types which provide validations for the user input, for example
pattern
,minLength
forstring
minItems
,maxItems
forarray
can have Custom Validation Messages
.
For each validation check within a property, plugin developers can provide a validation message. The validation message will be shown for the first failed validation check.
Schema Configuration¶
Attributes¶
Attribute | Value | Description |
---|---|---|
validationMessages | Object | Key-value to define validation messages for various input validation check keywords. |
Supported Keys¶
Keys | Applicable Data Type |
---|---|
minLength, pattern | string |
maxItems, minItems, uniqueItems | array |
multipleOf | integer, number |
Where¶
- As a Sub-schema of dxFormProperties.
Applicable Data Types¶
- string
- array
- integer
- number
Usage¶
{
"userName": {
"type": "string",
"minLength": 8,
"pattern": "postgre.*",
"dxFormProperties": {
"validationMessages": {
"minLength": "<Your Custom Validation Message which represents \"minLength\" validation check.>",
"pattern": "<Your Custom Validation Message which represents \"pattern\" validation check.>"
}
}
}
}
Examples¶
Examples
No error message will be shown in case of validation check failure.
Only minLength
validation error message will be shown in case of length constraint failure.
Both minLength
and pattern
validation error message will be shown based on input validation check failure.