fetchSubmissions -> gets all submissions in database
addSubmission -> allows users to create a new submission, saving it to the database
deleteSubmission -> allows users to delete submissions by ID
Submission Form
fetches all submissions in database on initialization of submission form
on submit -> locationName is verified to prevent duplicate submissions; if not duplicate, will add new submission to database; if duplicate, will alert user with popup and remain on submission form screen
Once a valid, new submission is saved, the form reloads to empty form -> this triggers the useState to fetch a new list of submissions and prevent adding the new submission again
Coming Up
Rate and Review component is not on there, the data is hardcoded. This will be changed with the rateandreview connection next.
Form will reload on successful submission, but eventually will reroute to location page by locationName
Submission Service
Submission Form
Coming Up