* Add next page path method with conditional routing
* Rename method
* Fix the tests and add files to .gitignore
* Make get_next_page_path a private method
* WIP test for total question count
* Change back button to use rails navigation
* Make total number of questions work with conditional routing and run rubocop
* Add tests for conditional question displaying
* Add conditional routing to the check answers page
* push 1 failure
* make total_questions step over the form like a user would and gather relevand questions
* Fix the tests
* fixed checks answers labels
* small refactors and rubocop
* remove unused code from get next page path
Co-authored-by: Kat <katrina@madetech.com>
Co-authored-by: magicmilo <milobascombe@gmail.com>
No errors need to be added if the net income is given as 0 but no frequency
is provided. It just needs to be made not required if the net income is
refused (given as 0) so that the record can still be added.
* use test_form.json in tests
* Pass in form to view from controller for check_answers
* reduce test json length for household section
* Further shorten the test json
* Remove extra radio questions from test json household section
* Trim test form and fix tests
* do some method extraction
* Extract creation of form into a formHandler
* rubocop
* redefine form model to use filepaths instead
* Check test env var in form handler
* remove singleton and make get_all_forms a private method
* refactor get_all_forms
Co-authored-by: Kat <katrina@madetech.com>
* Validate API created case logs
* Validate record completion
* Set complete or in progress status based on field presence validation
* Make autogenerated fields a named constant
* Test the whole validation
* Add some hated code comments to explain some things
* Be stricter about the params we allow mass updates on
* 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
* Form with model so that we can validate (hypothetically)
* Put turbo frame back
* Turbo can update form errors if submitting returns 422
* Refactor and fix specs
* String interpolation over concatenation
* Get and display subsection completion status in tasklist
* update gitignore
* Add styling change return of get status
* Make skip to next incomplete section functional
* update tasklist helper methods not to use the default form
* Display completed sections count
* shuffle if statement
* Pass question keys without the content to get the status
* remove return status, shuffle if statement
* Access styles and statuses directly