Locations: DB Model update & migration to add location table #463
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
It would be great to have 'location' as a separate table, rather than string on a spool.
This will allow us to print labels for locations, then scan a QR code label for a location and see what spools are in said location.
To do:
Update DB model to include a new 'location' table
Add a migration file to migrate existing locations (in spool) to create new locations and handle non-unique names etc.
Add UI screens for location model - including update spool location UI
Add a locations page - include view to see list of all spools in a location
Re-arrange spools between locations UI (drag and drop?) (stretch goal)
Add ability to print labels with QR codes for locations - upon scan show view to see list of all spools in a location
Update tests
Add test for migration to ensure existing string spool.location create a location object successfully. (Tested and passed manually)
Feedback as I go would be appreciated with and concerns / requests.
See #465 - please provide your thoughts