* Make outstanding amount question conditional
* Make major repairs date conditional on major repairs having been done
* Add Other reason for leaving as a conditional question
* Make reason for reasonable preference conditional on reasonable preference being given
* Refactor conditional html attributes
* Pretty print config json
* Add numeric conditional
* Add the rest of the conditionals
* Rubocop
* Refactor how we add stimulus controller html attributes so that we can combine them
* Spec attrib merging
* Fix question counts for sections with conditional questions
* Some linting
* Spec question counting behaviour
* Linting
* Add some more readme explanation
* Rename controller helper
* Rename variables for clarity
"header":"Please state the reason for leaving last settled home",
"hint_text":"",
"type":"text"
},
"benefit_cap_spare_room_subsidy":{
"header":"Was the reason for leaving because of the benefit cap or removal of the spare room subsidy?",
"hint_text":"",
@ -279,10 +681,10 @@
"household_needs":{
"label":"Household needs",
"pages":{
"armed_forces":{
"armed_forces":{
"header":"Experience of the UK Armed Forces",
"description":"",
"questions":{
"questions":{
"armed_forces":{
"header":"Has the tenant ever served in the UK armed forces?",
"hint_text":"",
@ -339,7 +741,7 @@
"medical_conditions":{
"header":"",
"description":"",
"questions":{
"questions":{
"medical_conditions":{
"header":"Does anyone in the household have any of the following that they expect to last for 12 months or more:<ul><li>Physical Condition</li><li>Mental Health Condition</li><li>Other Illness</li></ul>",
"hint_text":"",
@ -357,7 +759,7 @@
"pregnancy":{
"header":"",
"description":"",
"questions":{
"questions":{
"pregnancy":{
"header":"Is anyone in the household pregnant?",
"hint_text":"",
@ -374,7 +776,7 @@
"accessibility_requirements":{
"header":"",
"description":"",
"questions":{
"questions":{
"accessibility_requirements":{
"header":"Are any of these affected by their condition or illness?",
"hint_text":"Select all that apply",
@ -397,7 +799,7 @@
"condition_effects":{
"header":"",
"description":"",
"questions":{
"questions":{
"condition_effects":{
"header":"Are any of these affected by their condition or illness?",
"hint_text":"Select all that apply",
@ -430,10 +832,10 @@
"tenancy_information":{
"label":"Tenancy information",
"pages":{
"tenancy_code":{
"tenancy_code":{
"header":"",
"description":"",
"questions":{
"questions":{
"tenancy_code":{
"check_answer_label":"What is the tenancy code?",
"header":"What is the tenancy code?",
@ -470,10 +872,10 @@
}
}
},
"fixed_term_tenancy":{
"fixed_term_tenancy":{
"header":"",
"description":"",
"questions":{
"questions":{
"fixed_term_tenancy":{
"check_answer_label":"If the main tenancy is a fixed term tenancy, please provide the length of the fixed term (to the nearest year) excluding any starter/introductory period",
"header":"If fixed-term, what is the length of the fixed-term tenancy after any starter period?",
@ -546,10 +948,10 @@
"property_information":{
"label":"Property information",
"pages":{
"property_location":{
"property_location":{
"header":"",
"description":"",
"questions":{
"questions":{
"property_location":{
"check_answer_label":"Property Location",
"header":"Property location",
@ -873,10 +1275,10 @@
}
}
},
"property_postcode":{
"property_postcode":{
"header":"",
"description":"",
"questions":{
"questions":{
"property_postcode":{
"check_answer_label":"What was the previous postcode?",
"header":"What is the property's postcode?",
@ -932,7 +1334,7 @@
"property_reference":{
"header":"",
"description":"",
"questions":{
"questions":{
"property_reference":{
"check_answer_label":"What’s the property reference?",
"header":"What's the property reference?",
@ -966,7 +1368,7 @@
"property_number_of_bedrooms":{
"header":"",
"description":"",
"questions":{
"questions":{
"property_number_of_bedrooms":{
"check_answer_label":"How many bedrooms are there in the property?",
"header":"How many bedrooms are there in the property?",
@ -990,15 +1392,12 @@
"answer_options":{
"0":"Yes",
"1":"No"
}
}
},
"conditional_for":{
"property_major_repairs_date":["Yes"]
}
},
"property_major_repairs_date":{
"header":"",
"description":"",
"questions":{
"property_major_repairs":{
"check_answer_label":"What was the major repairs completion date?",
"header":"What was the major repairs completion date?",
"hint_text":"For example, 27 3 2007",
@ -1009,7 +1408,7 @@
"property_number_of_times_relet":{
"header":"",
"description":"",
"questions":{
"questions":{
"property_number_of_times_relet":{
"check_answer_label":"How many times has this unit been previously offered since becoming available for relet since the last tenancy ended or as a first let?",
"header":"How many times has this unit been previously offered since becoming available for relet since the last tenancy ended or as a first let? ",
@ -1047,10 +1446,10 @@
"income_and_benefits":{
"label":"Income and benefits",
"pages":{
"net_income":{
"net_income":{
"header":"",
"description":"",
"questions":{
"questions":{
"net_income":{
"check_answer_label":"Income",
"header":"What is the tenant’s /and partner’s combined income after tax?",
@ -1072,10 +1471,10 @@
}
}
},
"net_income_uc_proportion":{
"net_income_uc_proportion":{
"header":"",
"description":"",
"questions":{
"questions":{
"net_income_uc_proportion":{
"check_answer_label":"Benefits as a proportion of income",
"header":"How much of the tenant’s income is from Universal Credit, state pensions or benefits?",
"header":"Is the tenant likely to be in receipt of any of these housing-related benefits?",
@ -1116,10 +1515,10 @@
"rent":{
"label":"Rent",
"pages":{
"rent":{
"rent":{
"header":"",
"description":"",
"questions":{
"questions":{
"rent_frequency":{
"check_answer_label":"Rent Period",
"header":"Which period are rent and other charges due?",
@ -1187,7 +1586,7 @@
"step":1,
"readonly":true
},
"outstanding_amount":{
"outstanding_rent_or_charges":{
"check_answer_label":"After housing benefit and/or housing element of UC payment is received, will there be an outstanding amount for basic rent and/or benefit eligible charges?",
"header":"After housing benefit and/or housing element of UC payment is received, will there be an outstanding amount for basic rent and/or benefit eligible charges?",
"hint_text":"",
@ -1195,7 +1594,18 @@
"answer_options":{
"0":"Yes",
"1":"No"
},
"conditional_for":{
"outstanding_amount":["Yes"]
}
},
"outstanding_amount":{
"check_answer_label":"Outstanding amount",
"header":"What do you expect the amount to be?",
"hint_text":"If the amount is unknown you can estimate",
"type":"numeric",
"min":0,
"step":1
}
}
}
@ -1209,10 +1619,10 @@
"local_authority":{
"label":"Local authority",
"pages":{
"time_lived_in_la":{
"time_lived_in_la":{
"header":"",
"description":"",
"questions":{
"questions":{
"time_lived_in_la":{
"check_answer_label":"How long has the household continuously lived in the local authority area where the new letting is located?",
"header":"How long has the household continuously lived in the local authority area where the new letting is located?",
@ -1231,10 +1641,10 @@
}
}
},
"time_on_la_waiting_list":{
"time_on_la_waiting_list":{
"header":"",
"description":"",
"questions":{
"questions":{
"time_on_la_waiting_list":{
"check_answer_label":"How long has the household been on the local authority waiting list where the new letting is located?",
"header":"How long has the household been on the local authority waiting list where the new letting is located?",
@ -1253,10 +1663,10 @@
}
}
},
"previous_la":{
"previous_la":{
"header":"",
"description":"",
"questions":{
"questions":{
"previous_la":{
"check_answer_label":"The LA in which household lived immediately before this letting\t",
"header":"Which local authority area did the household live in immediately before this letting?",