silverstripe-framework/tests/php/Forms/FormSchemaTest/testSchemaValidation.json

135 lines
3.8 KiB
JSON
Raw Normal View History

2017-05-04 02:52:40 +02:00
{
"name": "TestForm",
"id": "Form_TestForm",
"action": null,
"method": "POST",
"attributes": {
"id": "Form_TestForm",
"action": null,
"method": "POST",
"enctype": "application\/x-www-form-urlencoded",
"target": null,
"class": ""
},
"data": [],
"fields": [
{
"name": "Name",
"id": "Form_TestForm_Name",
2017-05-09 06:42:08 +02:00
"type": "text",
"schemaType": "Text",
2017-05-04 02:52:40 +02:00
"component": null,
"holderId": "Form_TestForm_Name_Holder",
"title": "Name",
"source": null,
"extraClass": "text",
"description": null,
"rightTitle": null,
"leftTitle": null,
"readOnly": false,
"disabled": false,
"customValidationMessage": "",
"validation": {
"required": true,
"max": {
"length": 40
}
},
"attributes": [],
"data": []
},
{
"name": "Date",
"id": "Form_TestForm_Date",
2017-05-09 06:42:08 +02:00
"type": "date",
"schemaType": "Date",
2017-05-04 02:52:40 +02:00
"component": null,
"holderId": "Form_TestForm_Date_Holder",
"title": "Date",
"source": null,
"extraClass": "date text",
"description": null,
"rightTitle": null,
"lang": "en-US",
"leftTitle": null,
"readOnly": false,
"disabled": false,
"customValidationMessage": "",
"validation": {
"date": true
},
"attributes": [],
"data": {
"html5": true,
"min": null,
"max": null
}
},
{
"name": "Number",
"id": "Form_TestForm_Number",
2017-05-09 06:42:08 +02:00
"type": "number",
"schemaType": "Decimal",
2017-05-04 02:52:40 +02:00
"component": null,
"holderId": "Form_TestForm_Number_Holder",
"title": "Number",
"source": null,
"extraClass": "numeric text",
"description": null,
"rightTitle": null,
"leftTitle": null,
"readOnly": false,
"disabled": false,
"customValidationMessage": "",
"validation": {
"numeric": true
},
"attributes": [],
"data": []
},
{
"name": "Money",
"id": "Form_TestForm_Money",
2017-05-09 06:42:08 +02:00
"type": "text",
"schemaType": "Text",
2017-05-04 02:52:40 +02:00
"component": null,
"holderId": "Form_TestForm_Money_Holder",
"title": "Money",
"source": null,
"extraClass": "currency text",
"description": null,
"rightTitle": null,
"leftTitle": null,
"readOnly": false,
"disabled": false,
"customValidationMessage": "",
"validation": {
"currency": true
},
"attributes": [],
"data": []
},
{
"name": "SecurityID",
"id": "Form_TestForm_SecurityID",
2017-05-09 06:42:08 +02:00
"type": "hidden",
"schemaType": "Hidden",
2017-05-04 02:52:40 +02:00
"component": null,
"holderId": "Form_TestForm_SecurityID_Holder",
"title": "Security ID",
"source": null,
"extraClass": "hidden",
"description": null,
"rightTitle": null,
"leftTitle": null,
"readOnly": false,
"disabled": false,
"customValidationMessage": "",
"validation": [],
"attributes": [],
"data": []
}
],
"actions": []
2017-05-09 06:42:08 +02:00
}