Closed fungjj92 closed 5 years ago
Just merged #406. This will need to be rebased atop develop
to resolve the merge conflicts.
Updated, pretty straightforward rebase onto #406 whoo hoo communication 🎉
Thanks for reviewing! Will wait for Jenkins before merging.
Overview
This PR adds a functional April survey form that displays completed and submits new April surveys.
TODO's:
Connects #379
Demo
Basic error handling:
Notes
Things I'm thinking.
It would be awesome to have a custom component that all the monthly surveys inherit from, since their functionality will be the same I think. The only tricky thing is the forms are custom, and that puts a damper in reusability. --> Timebox explore in #380
~As discussed on slack #react, I wasn't sure how to handle the requests to the survey endpoints. It doesn't make sense to me to invoke Redux since survey data is very much only used in the scope of the modal being open. This is what I have that is working, for now. Open to discussion!~ Decided on making requests from component.
Testing Instructions
In
utils
change thestartYear
(line 192) ingetAprilSurveys
to 2018. Visit http://localhost:8000/survey/?beekeepers and click one of the April (APRIL) surveys. Fill out the survey if it doesn't exist, else see the results display.Other survey listings should open an empty popup which will be subbed in with their survey form components when they exist.