JSON Forms
Allowed Elements
- dateField
- text - read only text
- textField - user editable single line text input field
- textArea - multi-line user editable text input field
- dropDown - a select list of possible values allowing the user to select only one option
- list - a read only list of values
- group - a two column grouping of checkboxes
- toggle
dateField
{
"type":"dateField"
,"title":"Previous Pregnancy"
,"name":"Previous Pregnancy"
,"value":""
}
text
{
"type":"text"
,"value":"RISK RACTORS: Please select the appropriate values below that reflect your risk factors"
}
textField
{
"type":"textField"
,"title":"Alcohol drinks/day"
,"name":"Alcohol drinks/day"
,"value":"<1"
}
textArea
{
"type":"textArea"
,"title":"Simple Text Area"
,"name":"userFreeText"
,"value":"some very long winded text that can span multiple lines"
}
dropDown
{
"type":"dropDown"
,"title":"Does Patient Exercise"
,"name":"Does Patient Exercise"
,"placeHolder":"Choose one..."
,"value":""
,"options":[
{"display":"no","value":"no"}
,{"display":"yes","value":"yes"}
]
}
list
{
"type":"list",
"title":"Patient Medical History",
"options":[
"Atrial Fibrillation",
"Congestive Heart Failure",
"Hyperlipidemia",
"Hypertension"
]
}
group
{
"name": "Sexual History",
"title": "Sexual History",
"type": "group",
"elements": [
{
"highlight": "true",
"name": "Reviewed - No Changes Required",
"title": "Reviewed - No Changes Required",
"type": "checkBox",
"value": "false"
},
{
"name": "currently monogamous",
"title": "currently monogamous",
"type": "checkBox",
"value": "false"
},
{
"name": "multiple partners currently",
"title": "multiple partners currently",
"type": "checkBox",
"value": "false"
},
{
"name": "multiple partners in the past",
"title": "multiple partners in the past",
"type": "checkBox",
"value": "false"
},
{
"name": "sex for money",
"title": "sex for money",
"type": "checkBox",
"value": "false"
},
{
"name": "sex for drugs",
"title": "sex for drugs",
"type": "checkBox",
"value": "false"
},
{
"name": "same sex encounters",
"title": "same sex encounters",
"type": "checkBox",
"value": "false"
},
{
"name": "HIV + partner",
"title": "HIV + partner",
"type": "checkBox",
"value": "false"
}
]
}
toggle
{
"type":"toggle"
,"title":"Does Patient Exercise"
,"name":"Does Patient Exercise"
,"value":""
,"options":[
{"display":"no","value":"no"}
,{"display":"yes","value":"yes"}
]
}
How to build a form
To build a form enclose the elements of the form inside this wrapper inside the fields element
Elements:
- name - is the text that will be shown at the top of the iPad
- id - is what will be sent back to CCC when the form is fulfilled as the name of the form
{
"name":"Review of Systems",
"id": "ROS",
"description":"",
"fields":[]
}
How to send a set of forms for a patient
To send forms to the api include them in this wrapper inside of the forms array element
Patient Elements:
- id - the id of the patient from the EMR
- dateOfBirth - the date of birth from the EMR
- lastName - the last name of the patient from the EMR
{
"patient": {
"dateOfBirth": "10/31/1980"
,"id": "808"
,"lastName": "Jones"
}
,"metaData":{}
,"forms": []
}
Known metadata
{
"id": "CS1",
"name": "New Patient Questionnaire",
"metaData":{
"clinicalSummary" : "New Patient Questionnaire",
"destination" : "EMR",
"signed" : "true",
"privacy" : "true",
"release" : "true",
"benefits" : "true",
"importAsSigned" : "AO"
}