From c0ecdd4371a23df3357d71077760a37ef53e0645 Mon Sep 17 00:00:00 2001 From: Ferry Boender Date: Wed, 1 Apr 2015 09:02:06 +0200 Subject: [PATCH] Validate example. --- examples/validate/job_validate.sh | 5 +++++ examples/validate/validate.json | 28 ++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) diff --git a/examples/validate/job_validate.sh b/examples/validate/job_validate.sh index 51989b6..f2e121b 100755 --- a/examples/validate/job_validate.sh +++ b/examples/validate/job_validate.sh @@ -4,3 +4,8 @@ echo "string = $string" echo "integer = $integer" echo "float = $float" echo "date = $date" +echo "radio = $radio" +echo "text = $text" +echo "password = $password" +echo "file = $file" +echo "file name = $file__name" diff --git a/examples/validate/validate.json b/examples/validate/validate.json index 4d48eb2..688f4de 100644 --- a/examples/validate/validate.json +++ b/examples/validate/validate.json @@ -38,6 +38,34 @@ "required": true, "min": "2015-01-01", "max": "2015-02-01" + }, + { + "name": "radio", + "title": "A radio", + "type": "radio", + "required": true, + "options": [ + ["One", "one"], + ["Two", "two"], + ["Three", "three"] + ] + }, + { + "name": "text", + "title": "A text input field", + "type": "text", + "required": true, + "rows": 2, + "cols": 50, + "maxlen": 100, + "minlen": 10 + }, + { + "name": "password", + "title": "A password input field", + "type": "password", + "required": true, + "minlen": 5 } ] }