As an admin, I want to have CRUD functionalities (Create, Read, Update, Delete) for managing doctors on the admin page, so that I can efficiently add, edit, view, and remove doctor records as needed.
Acceptance Criteria
[x] Criterion 1: A list of doctors should be displayed on the admin page loaded from the database.
[x] Criterion 2: An "Add Doctor" button should be present on the admin page. Clicking this button should create a new row in the doctor table for inputting new doctor information.
[x] Criterion 3: Each doctor row should have "Edit" and "Delete" buttons.
[x] Criterion 4: When "Edit" is pressed, a dialogue box should open up to allow modifications to the doctor's information.
[x] Criterion 5: All basic error cases should be handled for adding and editing a doctor's data.
[x] Criterion 6: Ensure that the "Add Doctor" functionality successfully adds new doctor records to the database.
[x] Criterion 7: Ensure that the "Edit Doctor" functionality updates the existing doctor records in the database correctly.
[x] Criterion 8: Ensure that the "Delete Doctor" functionality removes the selected doctor record from the database.
[x] Criterion 9: Postman tests should be created to automate the addition of multiple doctors for testing purposes. These tests should ensure that all CRUD functionalities work correctly.
[x] Criterion 10: Ensure only an authorised and logged in admin can access the Admin Page and functionalities.
[x] Criterion 11: Create a (hard-coded) admin whenever the server starts.
Additional Information
Example JSON payloads for Postman tests.
Guidelines on how to handle validation errors and edge cases (e.g., duplicate entries, invalid data).
Notes
Dependencies: This user story depends on the setup of the backend API endpoints for CRUD operations on doctor records.
User Story
As an admin,
I want to have CRUD functionalities (Create, Read, Update, Delete) for managing doctors on the admin page,
so that I can efficiently add, edit, view, and remove doctor records as needed.
Acceptance Criteria
Additional Information
Notes