PA 10.3: Add support for deleting VidQuizzes and questions
- Due Oct 28, 2020 by 11:59pm
- Points 1
- Submitting a website url
- Available after Oct 14, 2020 at 12am
Copy the ca10-solutions code from the course Dropbox folder Links to an external site. (or a newer version of that code) to a new folder in your Git repository: pas/pa10.3. Update VidQuiz so that:
- the deleteQuestion and deleteVidQuiz functions in api.php are implemented according to the instructions
- the router already supports these functions
- add support for deleting a VidQuiz from the player view
- UI updates: e.g. by adding a button at the top of the player that then calls the deletion
- Client-side code updates:
- add a function in crud.js to handle deleting a VidQuiz using AJAX (hint: use deleteQuestion() as a template)
- add a listener for the delete button that calls that function
The UI and client-side code should already handle deleting a question (it's just the deleteQuestion in api.php that's missing).
Here's the rubric:
[ ] deleteQuestion() in api.php is correctly implemented: removes a question from the database
[ ] deleteVidQuiz() in api.php is correctly implemented: removes a VidQuiz and any associated questions from the database
[ ] there's a button to delete a VidQuiz in the play view
[ ] when the button is pressed, the VidQuiz is removed
[ ] there is function in crud.js that handles the AJAX call to the server to delete a specified VidQuiz
[ ] the code is well commented and styled
[ ] there is a header at the top of the file that includes the name of the author(s) and a brief description of the file
[ ] the PA folder includes a README.md file with the required information in it
Submitting PAs
Be sure to create a README.md with the following information:
- who you worked with (say "I worked alone" if you didn't have a partner)
- how long you spent on the assignment
- the PA option (and, if applicable, the earlier PA option it builds off of)
- a copy of the PA option's rubric, filled out (only submit if you can honestly check off each of the criteria)
- what the most challenging aspects were
- any lingering questions you have about the assignment
Commit and push your git repository to GitHub, then paste a link to your PA directory.