* feat: core functionality
* feat: update schema.rb
* feat: add link for privacy notice, refactor to separate tenant/buyer
* feat: make privacy notices open in new tab
* test: make previous tests pass
* test: add new tests
* feat: add la manual edit page
* feat: make autocomplete accesible and la readable
* feat: add correct skip and linking behaviour, also rename fallback page
* feat: add page not found and tidy la list
* feat: add redirection behaviour
* feat: add coping with nil add_another_location query string
* test: add postcodes mocks to return local authorities
* feat: validate local authority to not be nil or "Select an option"
* feat: persist add_another_location even on validation failure
* feat: remove url query parsing, put validation before values added to db
* refactor: spacing
* tests: add new tests for edit-local-authority
* tests: remove redundant bangs
* Add abstract log class and sales log class
Created a parent log class for sales log and lettings log. Any bits common
to both sales and lettings can live in the parent class. As the sales log
functionality is built up any commonalities with lettings log can be extracted
into the parent log class. The sales log model is set up without a json form
and instead the form is defined in code - like the setup section of the lettings
log.
* update sales logs controller
* update lettings controller specs
* update filter method name
* update organisations controller
* use lettings method
* Add deleted tests back
* lint
Co-authored-by: Kat <katrina@madetech.com>
Co-authored-by: Kat <kosiak.katrina@gmail.com>
* Replaced log CSV direct download with email
* Tidy up authorization of organisations controller
- We already have a method to authenticate the scope of the user, so we can reuse that.
* Use Rails routes instead of absolute paths for CSV download links
* Introduce base NotifyMailer to to abstract away shared Notify mail functionality
* Fix mailer spec name
* Add worker instance to PaaS manifest
* Add CSV download bucket instance name into environment
* Update tests for improved search term handling
* Fix download mailer tests
* Clarifying comments
Co-authored-by: natdeanlewissoftwire <nat.dean-lewis@softwire.com>
Co-authored-by: James Rose <james@jbpr.net>
This renames the case_log to lettings_log as everything we've written so
far has been geared towards lettings of social housing so it makes sense to
have the name describe this. This is also a precursor to adding in stuff for
sales logs (whatever shape that takes)
Co-authored-by: James Rose <james@jbpr.net>
* Back button on edit location page routes to check answers for locations
* Update path
Co-authored-by: James Rose <james@jbpr.net>
Co-authored-by: James Rose <james@jbpr.net>
* Mark scheme location as confirmed
* Route to check your answers after any changes are made to the scheme. Display change for all editable fields
* Add some functionality
* Display banners and redirect to check answers after editing location name
* Remove a test
* update locations confirmation
* reuse can_change_scheme_answer?
* Use path helpers
* Redirect to view scheme when trying to access create form pages for the scheme
(cherry picked from commit 761bf97dc2)
* add before action for confirmed schemes
* update location path
* lint
Co-authored-by: Dushan Despotovic <dushan@madetech.com>
We updated the copy of the accessibility statement in 91b797c but there was some copy missed from the original document provided to us. This change adds the missing copy, and bumps the last reviewed date on the statement.
* shows incomplete tag if the scheme is not confirmed
* displays a link to check answers page if the scheme is incomplete
* return schemes with no location when searching
* update tests
* lint
* spiked extra values for location la
* test
* extra test
* extra spacing
* renamed argument
* refactored per Dans suggestions
* redundant tests
* redundant method
* redundant method
* redundant method - part 3
* redundant method - part 4
* reset managing org for sheme
* only display schemes with managing org id
* only display relevant answers in show scheme page
* tests
* check arrangement type from saved scheme if incoming params for it is nil
* don't override managing org id if it's coming through as nil
* convert to use values that won't change for checks
* Revert "convert to use values that won't change for checks" because the value coming through from the params is the value and not a key
This reverts commit 50053ec0cf233e3a6c36db9af2528c354d3d60e7.
* Test
* check constant values
* Add test case for controller, check if the scheme is confirmed before displaying
* validate all the required scheme questions are answered
* fix ui
* fix test
* Add test, change error message wording
* Display error message next to the relevant field
* update context and query
* lint
Co-authored-by: Dushan Despotovic <dushan@madetech.com>
* failing test to display local authority
* passing tests - sadly with not allowed net connections
* added relevant tests and tweaked the webmock
* shorter output from api
* location_admin_district for location
* location_admin_district for location
* fixed tests
* Add search
* Add "Add location" button
* Add confirmed flag to schemes
* Show location tab is location is being added to an existing scheme
* Switch button text when scheme exists already
* Remove change links for confirmed schemes
* Fix spec after rebase
* added title showing search results and tests for it
Co-authored-by: JG <moarpheus@gmail.com>
* Fix data mapping for mantype
This was mapped to a column called support services provider which was an
integer, this now maps to the arrangement type column. This should be in
line with expectations for the import/export
* remove unused stuff
* lint fixes
* changes to comparison
* fix lambda checks in view
* fix export test
* Add mobility type question
* Remove wheelchair_adaptation, use mobility_type to infer wchair
* Add validatio to mobility type
* tests
* Rebase main
* CYA test
* extract selection methods into a helper
* validation error messages for scheme
* WIP for validations
* fixed redirects for a correct page
* expecting link to a new question
* added support_services_provider
* WIP for support_services_provider
* WIP for support_services_provider - works concenptually
* WIP passing feature tests
* WIP passing feature tests
* WIP validations
* passing tests and working functionality
* location validations
* fixed after rebasing
* fixed edit name
* fixed after rebasing
* tests for missing params
* tests for validations
* tests for validations locaion
* tests for validation of all params for scheme
* tests for location validations
* What is this type of scheme? - Order options alphabetically:
* Care Standards Act 2000? - Order options as follows, add missing hint text for third option
* further styling
* last UI changes
* lmoved back button logic to the view
* select options in the view
* missing validation for manaing org
* fixed check answers page
* wip
* small change
* fixed
* fixed check answers page ui
* fixed updating
* fixed tests
* fixed layout
* final touches
* rebase
* rubocop
* correct condition
* old test
* Add location startdate column to the db
* Display the schemes with active locations only when selecting a scheme for a case log
* When selecting a location for case log, only show active locations
* Add startdate to the form
* only display the number of active locations in the appended text
* Compare date instead of time
* Put location questions and hints into a translation file
* lint
* content change
* add synonyms, appended text and hint text to the autocomplete
* update test part 1
* refactor synonym, append and hint methods to take in resource
* Fix tests and lint
* Change min autocomplete character length to 1
* change test