-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feature/pdct 1780 support multiple geos in update (#278)
* feat: add function to retrieve list of geo ids from iso codes - function that retrieves the list of geo ids from the geo repo, based on the iso codes thats provided in the payload. It validates these iso codes at the same time returning an error if the geography does not exist in the db * feat: add geographies onto family write dto this will currently have a default value of none, so that it works with front end requests until the payload data is also updated * feat: add list of geo ids parameter to update function * feat: validate geography iso codes to get ids in family service * feat: update model for family geographies * test: integration tests for update endpoint with invalid geo id in list * test: update dto helpers with geographies property * chore: update project version * chore: update project version * tests: add final integration, testing multi geos are added * feat: default geographies to none on the model, to ensure that this does not break any requests made by the front before multi geos is implemented * fix: use geography repo mock in repo unit tests * chore: update project version * refactor: make update_geographies check a bit more explicit if the array of geo ids coming through is empty, i.e it was not passed int he payload as expected (the frontend hasnt been updted for multi geos we do nowt and carry on * test: fixing missing argument in rollbackrepo * feat: add linear ticket to todo comments - updating code once frontend multi geos has been implemented * refactor: split out family geo update functionality into separate methods * feat: helper functions for pergorming familygeo updates * refactor: update sql query to be more explicit * refactor : move functions into family repo and out of helpers * tests: add tests for repository errors * feat: wrap geography updates in a repository error --------- Co-authored-by: Osneil Drakes <osneildrakes@Osneils-MBP.communityfibre.co.uk> Co-authored-by: Osneil Drakes <osneildrakes@Osneils-MacBook-Pro.local>
- Loading branch information
1 parent
3d2f936
commit 47c9067
Showing
16 changed files
with
419 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.