This repository has been archived by the owner on Feb 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Conditionally change split operation to revert
In production we encountered a situation where a list item was used to create a facility but then through some sequence of moderation activities was matched to a different facility. Attempts to use split function in the dashboard failed because attempting to create a new facility from the list item violated the uniqueness constraint on `Facility.created_from`. To work around this problem we now include `facility_created_by_item` in the data used to populate the dashboard split tool and conditionally offer a "revert" option in place of split and mirror that change in the API view to connect the match to the originally created facility rather than attempting to make a new facility record.
- Loading branch information
Showing
4 changed files
with
87 additions
and
21 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