* Add in past end dates for testing
* Temporarily disable test marked to delete at year end
* Remove one off reinfer_local_authority task
* Update validator_spec
* Set 2024 date in form_handler_spec to be during crossover period as needed
* Use bulk_upload.year_combo for comparison in request tests to avoid year dependancy
* Update BU log creator specs for 2024
* Use year combo function in bulk upload mailer tests
* Refactor lettings validator_spec
* More fixes
* More work on bu validator specs - mostly sales
* Remove pre 2023 test
* More use of bulk_upload.year_combo in request tests
* Fix lint
* Tweak bulk upload error row component tests for year changes
* Further fixes
* Fix 2023 lettings row parser spec
* Sales log to csv fix
* Refactor BU processor tests
* Fix field number row identifier
* Fix linting
* More years in request spec
* fix
* Don't use db unnecessarily in financial validations spec
* Fix sale date changing 2024 -> 2023 test
* Add tests for bulk_upload.year_combo
* Update bu factory year specification
* Refactoring
* Linting
* Don't use helper in factory
* Remove new 2023 specific test
* Remove dummy end dates
* further fixes
* Fix date / crossover issues
* Try changing form end dates
* Revert "Try changing form end dates"
This reverts commit e027e29cf0.
* Make use of :ignore-validation-errors trait
* Try with end dates in past
* Revert "Try with end dates in past"
This reverts commit 6b87938d70.
---------
Co-authored-by: Rachael Booth <rachael.booth@softwire.com>
* CLDC-3487: Clear previous_la_known when necessary for renewal logs
* CLDC-3487: Clear location when clearing scheme due to org change
* CLDC-3487: Use nil instead of 0
* Specify orgs on sh logs when needed for tests
* Fix flaky tests
* Empty
* CLDC-3345 Rename created_by to assigned_to (#2372)
* Rename created_by to assigned_to
* Replace created_by with assigned_to
* Update created_by to assigned_to in exports, remove blank assigned to
* CLDC-3345 Add and set created_by fields (#2373)
* Add created_by
* Update existing created_by values
* Set created_by on single log
* Set created_by on BU
* Add created_by to exports
* feat: update since last merge
---------
Co-authored-by: natdeanlewissoftwire <nat.dean-lewis@softwire.com>
* Fix papertrail create version
---------
Co-authored-by: natdeanlewissoftwire <nat.dean-lewis@softwire.com>
* Update feature tests
* Remove old rake tasks
* Update some unit tests
* Update more tests
* More tests
* Fix failing sales household validation test
---------
Co-authored-by: Robert Sullivan <robert.sullivan@softwire.com>
* Update schemes from csv
* Handle validation errors
* update locations from csv
* Export logs using updated schemes and locations
* Refactor
* Only update owning org to related ort
* Update logs
* Log and not update old logs
* do not update the org with closed collection logs
* Do not export old logs with changed location
* Rename logs and refactor tests
* Handle rent ranges for open collection periods
* Log ids for logs that turn in progress
* Allow changing scheme to the one from related org
* log updates logs and don't mark them unesolved
* Clear scheme/location if location scheme changes
* Check soft rent validation for closed collection
* Clear location/scheme in remaining exportable logs
* Log updates before clearing locations and schemes
* Empty commit
* CLDC-3224: Parse noint correctly in bulk upload row parsers
* CLDC-3224: Add task to fix previous noint data
* CLDC-3224: Remove nonsensical value for noint field in bu test
* CLDC-3224: Move where bulk upload noint fix status is set to ensure it matches processing version
* Put BU noint_fix_status setting before creating any logs
* Set and clear duplicate log references
* Export duplicate_log_reference_id for lettings
* Export duplicate_log_reference_id for sales
* Export duplicate_log_reference_id in xml
* Update existing duplicate log references
* Add missing sales deduplication steps
* Set duplicate_set_id straight on logs
* Do not update updated_at to prevent export
* Increment duplicate_set_id
* Update duplicates when they change sets
* Remove duplicates when deleting logs
* Create DuplicateLogReference
* Set and clear duplicate log references
* Export duplicate_log_reference_id for lettings
* Export duplicate_log_reference_id for sales
* Export duplicate_log_reference_id in xml
* Update tests
* Update existing duplicate log references
* Rename a field
* Add missing sales deduplication steps
* Set duplicate_set_id straight on logs
* Do not update updated_at to prevent export
* Increment duplicate_set_id
* Update duplicates when they change sets
* Remove duplicates when deleting logs
* correctly update duplicate set IDs when answer is changed through normal form flow
* Correctly route to sales owning organisation page
* Display correct owning organisation options
* Set managing organisation as user organisation
* Add managing organisation question for sales
* Display managing organisation users in created_by
* set managing org to be same as owning org in BU
* Add managed by filter to sales
* Display reported by, correctly update owning org
* Update factory and 2022 BU
* refactor
* Merge managed sales logs
* test
* Update managing organisation for sales bulk upload
* Rebase tests
* skip a test as it is not relevant as the rake task would have already been ran
* PO fixes
* Remove old collection managed sales validation
* Update question header and filters conditions
* remove feature toggle
* feat: only show editable duplicate sets for user and org
* feat: simplify and refactor
* feat: update tests
* feat: add and update tests
* feat: reset not routed questions twice to catch newly not routed questions after the first set are cleared
* Revert "feat: reset not routed questions twice to catch newly not routed questions after the first set are cleared"
This reverts commit 3007284670.
* TEST FOR PO TO BE REVERTED
* TEST FOR PO TO BE REVERTED (set back to dec 31)
* TEST UPDATE TESTS
* REVERT THIS TEST UPDATE
* REVERT THIS TEST UPDATE
* feat: timecop tests
* refactor: lint
* feat: add update methods
* feat: update tests (and TO BE REVERTED: change collection year)
* feat: update tests
* feat: update tests
* feat: update form end_date tests REVERT LATER
* feat: update tests
* refactor: lint
* feat: revert to previous end dates now passed PO review
* feat: use scoping to simplify editable set logic
* feat: set encoding by bom for file IO before parsing
* feat: set bom encoding for illness task as well
* feat: use StringIOs in testing and fix row count bug found
* feat: revert toheaders: false
* feat: timecop around tests
* feat: timecop around tests
* feat: fix flaky merge test
* feat: skip over logs that fail validations
* feat: test error added correctly and fix typo
* feat: set encoding by bom for file IO before parsing
* feat: set bom encoding for illness task as well
* feat: use StringIOs in testing and fix row count bug found
* feat: revert toheaders: false
* feat: timecop around tests
* feat: timecop around tests
* feat: fix flaky merge test
* feat: set encoding by bom for file IO before parsing
* feat: set bom encoding for illness task as well
* feat: use StringIOs in testing and fix row count bug found
* feat: revert toheaders: false
* Allow custom merge date in merge organisations service
* Allow optional merge date in merge orgs task
* Add a rake task for merging into a new organinsation
* CLDC-2895 Add squish to the names of locations, schemes, users, and institutions
* CLDC-2895 Add rake task to squish the names of all locations, schemes, users, and organisations
* CLDC-2895 Add tests to squish_names rake tasks
* Add missing addresses csv job
* Update missing addresses csv service methods
* Add rake task
* Update the job to send missing town or city templates
* Update service to create mising town or city templates
* Add send missing town or city csv rake task
* Add IDs to the CSVs
* Put all log in the same csv
* Add issue type column
* Write wrong uprn logs to csv
* Add mailer methods
* Skip uprn issue for specified orgs
* Add sales csv rake task
* set SKIP_UPRN_ISSUE_ORG_IDS on review apps
* test
* Update notify template IDs for testing
* Initialize service with organisation instead of a hash
* Add expiration time to url
* Add optional tags and remove LA from csv
* Extract log to csv methods
* Update casing
* Update old IDs in factories
* Move constant
* Extract some repeating scopes
* Pass in organisations to skip instead of using an env var
* update template id for sales
* Update link expiry time and headers
* Lower the threshold for testing
* Add issue explanation to the email
* Add how to fix
* update emails
* CLDC-2810 Create all addresses CSV (#1953)
* Add rake tasks for creating all addresses CSV
* Write headers if logs don't exist, update header names
* Rename method
* CLDC-2810 Correct addresses from csv (#1957)
* Updating importing lettings addresses form csv
* Add import_sales_addresses_from_csv rake
* Allow correcting addresses from both templates
* escape .
* Reinfer LA if the postcode hasn't changed
* Update labels and email content
* Update missing addresses threshold
* Remove unused env var
* Adjust xml export to export refused details, update refused to take into account details_unknown
* Recalculate refused values for lettings logs with unknown person details
* Export refused values in the csv
* Update file names
* Move single person details if person 2 details are missing
* Allow reimporting details for any single missing person
* Reimport multiple missing person details, skip logs with no extra person details
* Skip update if record does not have hhmemb value
* Refactor
* Rebase change
* Extract method