field validator required, allowZero
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Sebastian Frank 2022-10-27 16:48:27 +02:00
parent f738754f04
commit 30e7eb2db8

View File

@ -61,7 +61,16 @@
"validator": {
"type": "object",
"description": "field validator",
"additionalProperties": false,
"properties": {
"required": {
"type": "boolean",
"description": "force field as required"
},
"allowZero": {
"type": "boolean",
"description": "allow for required fields that the value can be an empty string or 0 for number type"
},
"eval": {
"type": "string",
"description": "javascript validator which failes if evaluates to false or string as error message, with following variables: $this, $parent, $stack, $auth, context"