This PR updates the Photo model to accommodate the format of the final dataset. Specifically:
Adds a folder field to Photo, which joins number and map_square in unique_together.
Wherever we previously looked for photos based on map_square and number, we now add folder, since there can be multiple photos with the same number in a map square but in different subfolders
Updated integrate_new_images to do so from the final dataset. It no longer renames files in place, as we're planning on retaining the original filenames.
Pushes all photo/slide image url generation to the backend (Fixes #246)
Probably shouldn't be in this PR but it was helpful for this work:
Adds dev_local_db and dev_admin_db settings files to make it easier for folks to either use a local sqlite3 db or login to the remote db with admin privileges. (@czheng10 -- take a look at this and ask me or @jeffreyshen19 if you need help using it for your team).
This PR updates the Photo model to accommodate the format of the final dataset. Specifically:
folder
field toPhoto
, which joinsnumber
andmap_square
inunique_together
.map_square
andnumber
, we now addfolder
, since there can be multiple photos with the same number in a map square but in different subfoldersintegrate_new_images
to do so from the final dataset. It no longer renames files in place, as we're planning on retaining the original filenames.Probably shouldn't be in this PR but it was helpful for this work:
dev_local_db
anddev_admin_db
settings files to make it easier for folks to either use a local sqlite3 db or login to the remote db with admin privileges. (@czheng10 -- take a look at this and ask me or @jeffreyshen19 if you need help using it for your team).