From 2dee5ea25e480af6e9cab3a2394af3cbc93a34e2 Mon Sep 17 00:00:00 2001 From: tijsziere <39266480+tijsziere@users.noreply.github.com> Date: Fri, 20 Dec 2024 11:30:28 +0100 Subject: [PATCH 1/2] Merge into prod (#65) * merge main into dev (#58) * merge dev into main - fix empty label in create 121 program (#53) * fix empty label bug * Add support for barcode question type (#54) * fix empty label bug * improve clarity * fix error * add support for kobo barcode questiontype --------- Co-authored-by: Jacopo Margutti * exception: map fspName to programFinancialServiceProviderConfigurationName * exception for nlrc * Update test_koboto121.py Change fspName to programFinancialServiceProviderConfigurationName in test * Changed endpoint url path post registrations Signed-off-by: Ruben * Update README.md * remove nlrc exceptions --------- Signed-off-by: Ruben Co-authored-by: Jacopo Margutti Co-authored-by: Sanne Berendschot Co-authored-by: Ruben Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com> Co-authored-by: Daan Gorsse <110089322+DGorsseRedCross@users.noreply.github.com> --- README.md | 12 +++++++++++- routes/routes121.py | 7 ++----- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 64b5ae2..42b5f3c 100644 --- a/README.md +++ b/README.md @@ -56,7 +56,7 @@ https://kobo-connect.azurewebsites.net/kobo-to-espocrm 6. Add the following headers under `Custom HTTP Headers`: - Under `Name` insert `targeturl` and under `Value` the EspoCRM URL (for example, https://espocrminstancex.com). - Under `Name` insert `targetkey` and under `Value` the (newly) created API Key (from EspoCRM API User). -9. For each question, add a header that specifies which Kobo questions corresponds to which entity and field EspoCRM: +9. For each question, add a header that specifies which Kobo questions corresponds to which entity and field EspoCRM: (tip: this is a manual task. If you want to semi-automatically add headers, read this [section](#create-headers-endpoint) on the creating headers endpoint) - The header name (left) must correspond to the Kobo question **name**. (You can check the Kobo question name by going into edit mode of the form, open 'Settings' of the specific question and inspect the `Data Column Name`. Also, the Kobo question names can be found in the 'Data' table with previous submissions. This Kobo question name is different from the [Kobo question label](https://support.kobotoolbox.org/getting_started_xlsform.html#adding-questions) and can not contain spaces or symbols (except the underscore).). - The header value (right) must correspond to the EspoCRM entity **name**, followed by a dot (`.`), followed by the specific field **name**. Example: `Contact.name`. (EspoCRM name is different from the EspoCRM label, similar to the difference between Kobo question name and Kobo question label). @@ -141,6 +141,16 @@ In the body you can pass all the headers you want to create as key value pairs, "household_size": "hhSize" } ``` +Tip: When you have the headers (/mapping) for example in an Excel table, you can copy that into ChatGPT and ask it to transform the table to key value pairs. It might save time setting up the body needed. The steps for this are the following: +1. Download the Kobo form in XLS (go to the 'FORM' tab in Kobo -> click the three horizontal dots (settings) -> 'Download XLS' +2. Open the XLS and copy the values from the 'name' column +3. Go to ChatGPT (or other LLM) and prompt the following: + ```` + Make key value pairs with the following keys and values in JSON output. For every value add "." in front. These are the headers: + ```` +4. Copy the output and paste in the ['Request body'](https://kobo-connect.azurewebsites.net/docs#/default/create_kobo_headers_create_kobo_headers_post) +5. Execute the script and confirm that a new REST service in Kobo has been created with the correct headers. + Tip: When you have the headers (/mapping) for example in an Excel table, you can copy that into ChatGPT and ask it to transform the table to key value pairs. It might save time setting up the body needed. diff --git a/routes/routes121.py b/routes/routes121.py index a7c2f00..9684363 100644 --- a/routes/routes121.py +++ b/routes/routes121.py @@ -72,7 +72,7 @@ async def kobo_to_121(request: Request, dependencies=Depends(required_headers_12 payload[target_field] = int(kobo_data[kobo_field]) elif target_field == "scope": payload[target_field] = clean_text(kobo_data[kobo_field]) - elif target_field == "fspName" and "nlrc.121.global" not in request.headers["url121"]: + elif target_field == "fspName": payload["programFinancialServiceProviderConfigurationName"] = kobo_data[kobo_field] elif kobo_value_url not in attachments.keys(): payload[target_field] = kobo_data[kobo_field] @@ -91,10 +91,7 @@ async def kobo_to_121(request: Request, dependencies=Depends(required_headers_12 access_token = login121(request.headers["url121"], request.headers["username121"], request.headers["password121"]) - if 'nlrc.121.global' in request.headers['url121']: - url = f"{request.headers['url121']}/api/programs/{programid}/registrations/import" - else: - url = f"{request.headers['url121']}/api/programs/{programid}/registrations" + url = f"{request.headers['url121']}/api/programs/{programid}/registrations" # POST to 121 import endpoint import_response = requests.post( url, From cd0f29f1ea6bb6e5a986d8bc0d3533001b538231 Mon Sep 17 00:00:00 2001 From: tijsziere <39266480+tijsziere@users.noreply.github.com> Date: Wed, 22 Jan 2025 10:11:26 +0100 Subject: [PATCH 2/2] Merge Dev into Main (#67) * merge main into dev (#58) * merge dev into main - fix empty label in create 121 program (#53) * fix empty label bug * Add support for barcode question type (#54) * fix empty label bug * improve clarity * fix error * add support for kobo barcode questiontype --------- Co-authored-by: Jacopo Margutti * exception: map fspName to programFinancialServiceProviderConfigurationName * exception for nlrc * Update test_koboto121.py Change fspName to programFinancialServiceProviderConfigurationName in test * Changed endpoint url path post registrations Signed-off-by: Ruben * Update README.md * remove nlrc exceptions * Included not in payment export (#66) * Merge into prod (#65) * merge main into dev (#58) * merge dev into main - fix empty label in create 121 program (#53) * fix empty label bug * Add support for barcode question type (#54) * fix empty label bug * improve clarity * fix error * add support for kobo barcode questiontype --------- Co-authored-by: Jacopo Margutti * exception: map fspName to programFinancialServiceProviderConfigurationName * exception for nlrc * Update test_koboto121.py Change fspName to programFinancialServiceProviderConfigurationName in test * Changed endpoint url path post registrations Signed-off-by: Ruben * Update README.md * remove nlrc exceptions --------- Signed-off-by: Ruben Co-authored-by: Jacopo Margutti Co-authored-by: Sanne Berendschot Co-authored-by: Ruben Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com> Co-authored-by: Daan Gorsse <110089322+DGorsseRedCross@users.noreply.github.com> * Removed included from export * change test accordingly * also remove phoneNumber from payment export, fix tests * remove print --------- Signed-off-by: Ruben Co-authored-by: tijsziere <39266480+tijsziere@users.noreply.github.com> Co-authored-by: Jacopo Margutti Co-authored-by: Sanne Berendschot Co-authored-by: Ruben Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com> Co-authored-by: Daan Gorsse <110089322+DGorsseRedCross@users.noreply.github.com> --------- Signed-off-by: Ruben Co-authored-by: Jacopo Margutti Co-authored-by: Sanne Berendschot Co-authored-by: Ruben Co-authored-by: RubenGeo <34537157+RubenGeo@users.noreply.github.com> Co-authored-by: Daan Gorsse <110089322+DGorsseRedCross@users.noreply.github.com> Co-authored-by: Wessel de Jong --- routes/routes121.py | 4 +- tests/program121.json | 1067 ++++++++++++++++++----------------------- 2 files changed, 474 insertions(+), 597 deletions(-) diff --git a/routes/routes121.py b/routes/routes121.py index 9684363..7286c7b 100644 --- a/routes/routes121.py +++ b/routes/routes121.py @@ -373,7 +373,7 @@ async def create_121_program_from_kobo( "pattern": "", "phases": [], "editableInPortal": True, - "export": ["all-people-affected", "included"], + "export": ["all-people-affected"], "shortLabel": { "en": row["name"], }, @@ -404,7 +404,7 @@ async def create_121_program_from_kobo( "pattern": "", "phases": [], "editableInPortal": True, - "export": ["all-people-affected", "included"], + "export": ["all-people-affected"], "shortLabel": { "en": row["name"], }, diff --git a/tests/program121.json b/tests/program121.json index 32bbf1d..2f609b0 100644 --- a/tests/program121.json +++ b/tests/program121.json @@ -1,600 +1,477 @@ { - "published":true, - "validation":true, - "phase":"registrationValidation", - "location":"Netherlands", - "ngo":"RCRC", - "titlePortal":{ - "en":"Template Create Program" + "published": true, + "validation": true, + "phase": "registrationValidation", + "location": "Netherlands", + "ngo": "RCRC", + "titlePortal": { + "en": "Template Create Program" + }, + "titlePaApp": { + "en": "Template Create Program" + }, + "description": { + "en": "" + }, + "startDate": "2024-07-03T00:00:00", + "endDate": "2024-07-31T00:00:00", + "currency": "EUR", + "distributionFrequency": "week", + "distributionDuration": 4, + "fixedTransferValue": 100, + "paymentAmountMultiplierFormula": "", + "financialServiceProviders": [ + { + "fsp": "Commercial-bank-ethiopia" + } + ], + "targetNrRegistrations": 10, + "tryWhatsAppFirst": false, + "phoneNumberPlaceholder": "32000000000", + "programCustomAttributes": [], + "programQuestions": [ + { + "name": "province", + "label": { + "en": "What is the province?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "South-Holland", + "label": { + "en": "South-Holland" + } + }, + { + "option": "North-Holland", + "label": { + "en": "North-Holland" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "province" + }, + "duplicateCheck": false, + "placeholder": "" }, - "titlePaApp":{ - "en":"Template Create Program" + { + "name": "city", + "label": { + "en": "What is the city?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Amsterdam", + "label": { + "en": "Amsterdam" + } + }, + { + "option": "Haarlem", + "label": { + "en": "Haarlem" + } + }, + { + "option": "Den Haag", + "label": { + "en": "Den Haag" + } + }, + { + "option": "Rotterdam", + "label": { + "en": "Rotterdam" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "city" + }, + "duplicateCheck": false, + "placeholder": "" }, - "description":{ - "en":"" + { + "name": "scope", + "label": { + "en": "scope" + }, + "answerType": "text", + "questionType": "standard", + "options": [], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "scope" + }, + "duplicateCheck": false, + "placeholder": "" }, - "startDate":"2024-07-03T00:00:00", - "endDate":"2024-07-31T00:00:00", - "currency":"EUR", - "distributionFrequency":"week", - "distributionDuration":4, - "fixedTransferValue":100, - "paymentAmountMultiplierFormula":"", - "financialServiceProviders":[ - { - "fsp":"Commercial-bank-ethiopia" - } - ], - "targetNrRegistrations":10, - "tryWhatsAppFirst":false, - "phoneNumberPlaceholder":"32000000000", - "programCustomAttributes":[ - - ], - "programQuestions":[ - { - "name":"province", - "label":{ - "en":"What is the province?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"South-Holland", - "label":{ - "en":"South-Holland" - } - }, - { - "option":"North-Holland", - "label":{ - "en":"North-Holland" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"province" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"city", - "label":{ - "en":"What is the city?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Amsterdam", - "label":{ - "en":"Amsterdam" - } - }, - { - "option":"Haarlem", - "label":{ - "en":"Haarlem" - } - }, - { - "option":"Den Haag", - "label":{ - "en":"Den Haag" - } - }, - { - "option":"Rotterdam", - "label":{ - "en":"Rotterdam" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"city" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"scope", - "label":{ - "en":"scope" - }, - "answerType":"text", - "questionType":"standard", - "options":[ - - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"scope" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"fullName", - "label":{ - "en":"What is your name?" - }, - "answerType":"text", - "questionType":"standard", - "options":[ - - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"fullName" - }, - "duplicateCheck":true, - "placeholder":"" - }, - { - "name":"age", - "label":{ - "en":"What is your age?" - }, - "answerType":"numeric", - "questionType":"standard", - "options":[ - - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"age" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"sex", - "label":{ - "en":"What is your sex?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Female", - "label":{ - "en":"Female" - } - }, - { - "option":"Male", - "label":{ - "en":"Male" - } - }, - { - "option":"Other", - "label":{ - "en":"Other" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"sex" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"idNumber", - "label":{ - "en":"What is your ID number?" - }, - "answerType":"numeric", - "questionType":"standard", - "options":[ - - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"idNumber" - }, - "duplicateCheck":true, - "placeholder":"" - }, - { - "name":"phoneNumber", - "label":{ - "en":"Phone Number" - }, - "answerType":"tel", - "questionType":"standard", - "options":[ - - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"phoneNumber" - }, - "duplicateCheck":true, - "placeholder":"" - }, - { - "name":"hhSize", - "label":{ - "en":"What is the amount of members in your household?" - }, - "answerType":"numeric", - "questionType":"standard", - "options":[ - - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"hhSize" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"selectionSingleHeaded", - "label":{ - "en":"Is this a single parent headed household?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Yes", - "label":{ - "en":"Yes" - } - }, - { - "option":"No", - "label":{ - "en":"No" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"selectionSingleHeaded" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"selectionElderlyHeaded", - "label":{ - "en":"Is this an elderly headed household?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Yes", - "label":{ - "en":"Yes" - } - }, - { - "option":"No", - "label":{ - "en":"No" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"selectionElderlyHeaded" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"selectionIllness", - "label":{ - "en":"Are there people with serious and/or chronic illness in the household?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Yes", - "label":{ - "en":"Yes" - } - }, - { - "option":"No", - "label":{ - "en":"No" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"selectionIllness" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"selectionDisability", - "label":{ - "en":"Are there people with disabilities in the household?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Yes", - "label":{ - "en":"Yes" - } - }, - { - "option":"No", - "label":{ - "en":"No" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"selectionDisability" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"selectionDisplaced", - "label":{ - "en":"Is the household displaced?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Yes", - "label":{ - "en":"Yes" - } - }, - { - "option":"No", - "label":{ - "en":"No" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"selectionDisplaced" - }, - "duplicateCheck":false, - "placeholder":"" - }, - { - "name":"selectionUnemployment", - "label":{ - "en":"Is the head of household unemployed?" - }, - "answerType":"dropdown", - "questionType":"standard", - "options":[ - { - "option":"Yes", - "label":{ - "en":"Yes" - } - }, - { - "option":"No", - "label":{ - "en":"No" - } - } - ], - "scoring":{ - - }, - "persistence":true, - "pattern":"", - "phases":[ - - ], - "editableInPortal":true, - "export":[ - "all-people-affected", - "included" - ], - "shortLabel":{ - "en":"selectionUnemployment" - }, - "duplicateCheck":false, - "placeholder":"" - } - ], - "aboutProgram":{ - "en":"Any text here" + { + "name": "fullName", + "label": { + "en": "What is your name?" + }, + "answerType": "text", + "questionType": "standard", + "options": [], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "fullName" + }, + "duplicateCheck": true, + "placeholder": "" }, - "fullnameNamingConvention":[ - "fullName" - ], - "languages":[ - "en" - ], - "enableMaxPayments":true, - "allowEmptyPhoneNumber":false, - "enableScope":false - } \ No newline at end of file + { + "name": "age", + "label": { + "en": "What is your age?" + }, + "answerType": "numeric", + "questionType": "standard", + "options": [], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "age" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "sex", + "label": { + "en": "What is your sex?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Female", + "label": { + "en": "Female" + } + }, + { + "option": "Male", + "label": { + "en": "Male" + } + }, + { + "option": "Other", + "label": { + "en": "Other" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "sex" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "idNumber", + "label": { + "en": "What is your ID number?" + }, + "answerType": "numeric", + "questionType": "standard", + "options": [], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "idNumber" + }, + "duplicateCheck": true, + "placeholder": "" + }, + { + "name": "phoneNumber", + "label": { + "en": "Phone Number" + }, + "answerType": "tel", + "questionType": "standard", + "options": [], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "phoneNumber" + }, + "duplicateCheck": true, + "placeholder": "" + }, + { + "name": "hhSize", + "label": { + "en": "What is the amount of members in your household?" + }, + "answerType": "numeric", + "questionType": "standard", + "options": [], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "hhSize" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "selectionSingleHeaded", + "label": { + "en": "Is this a single parent headed household?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Yes", + "label": { + "en": "Yes" + } + }, + { + "option": "No", + "label": { + "en": "No" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "selectionSingleHeaded" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "selectionElderlyHeaded", + "label": { + "en": "Is this an elderly headed household?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Yes", + "label": { + "en": "Yes" + } + }, + { + "option": "No", + "label": { + "en": "No" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "selectionElderlyHeaded" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "selectionIllness", + "label": { + "en": "Are there people with serious and/or chronic illness in the household?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Yes", + "label": { + "en": "Yes" + } + }, + { + "option": "No", + "label": { + "en": "No" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "selectionIllness" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "selectionDisability", + "label": { + "en": "Are there people with disabilities in the household?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Yes", + "label": { + "en": "Yes" + } + }, + { + "option": "No", + "label": { + "en": "No" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "selectionDisability" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "selectionDisplaced", + "label": { + "en": "Is the household displaced?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Yes", + "label": { + "en": "Yes" + } + }, + { + "option": "No", + "label": { + "en": "No" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "selectionDisplaced" + }, + "duplicateCheck": false, + "placeholder": "" + }, + { + "name": "selectionUnemployment", + "label": { + "en": "Is the head of household unemployed?" + }, + "answerType": "dropdown", + "questionType": "standard", + "options": [ + { + "option": "Yes", + "label": { + "en": "Yes" + } + }, + { + "option": "No", + "label": { + "en": "No" + } + } + ], + "scoring": {}, + "persistence": true, + "pattern": "", + "phases": [], + "editableInPortal": true, + "export": ["all-people-affected"], + "shortLabel": { + "en": "selectionUnemployment" + }, + "duplicateCheck": false, + "placeholder": "" + } + ], + "aboutProgram": { + "en": "Any text here" + }, + "fullnameNamingConvention": ["fullName"], + "languages": ["en"], + "enableMaxPayments": true, + "allowEmptyPhoneNumber": false, + "enableScope": false +}