casa
casa copied to clipboard
draft case contact cleanup
What github issue is this PR for, if any?
Resolves #5442
What changed, and why?
Added a scope to CaseContact to return drafts without an attached case as well as drafts older than one week. The rake task actually deletes the case contact. The task will need to be added to Heroku task scheduler.
How is this tested? (please write tests!) 💖💪
There's a model test on CaseContact that tests different scenarios and ensures only case contacts that should be cleaned up are returned.
Screenshots please :)
Before running rake task:
After running rake task:
Feelings gif (optional)

Cool stuff :)
This PR has been open for a long time without any pushes or comments! What's up?