alan-turing-institute / alan-turing-institute/AutSPACEs
Move placeholder uuids from file to database
- Dominant language
- Python
- Stars
- 43
- Forks
- 17
- PR merge metrics
- No merged PRs in 30d
Description
### Summary
Currently the uuids and image filenames for the story carousel on the home page are read from the carousel.json file.
Although it makes sense (I think) to store the placeholder stories in a file (because they should be available for use even if the database is cleared) it would make much more if the uuids for the *real* stories were stored in the databse.
This has two benefits:
1. They could be easily updated using the admin interface.
2. If the story is wiped from the databse the uuid could be automatically removed as well.
### What needs to be done?
- [ ] Create a model to capture story uuids and image filenames. There doesn't have to be any associated form or UI.
- [ ] Switch the `get_carousel_stories()` helper method to use the database entries rather than reading them from the `stories` entry in carousel.json.
### Who can help?
* Anyone will to hack the code.
Contributor guide
No contributing guide indexed for this repository
Research direction
Read carousel.json and locate the get_carousel_stories() helper first, then inspect existing story and database model patterns. The work is complete when a model captures story UUIDs and image filenames and the helper uses database entries for real stories while retaining the stated placeholder behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend, database
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100