added feature such that no of new appointments are shown in All, Emergency and Normal tabs for the current logged in admin.
When an admin logs in, if there are any new appointment request, a toast is triggered to show the number of new appointments to work on.
The new appointments are highlighted on the dashboard to inform the admin. The highlight goes away when the admin clicks and views the appointment.
If an admin is already logged in and a new appointment request is made, the dashboard updates in realtime highlighting the new request and a toast notification is triggered to inform the admin.
Removed the separate API calls for each type of appointment. Now, we have only one API call and the rest is taken care by the code.
Added modified date column to the DB
Updated the code such that the appointments in the Scheduled and Cancelled Tabs are sorted by modified date column as it seems more logical.
Related Issue
Closes #120 and #115
Acceptance Criteria
[x] No of new appointments should be shown in each tab for the current logged in admin.
[x] Toast probably for any new Emergency appointments.
[x] If the appointment is new, it should appear in bold in the dashboard to for users to differentiate visually.
[x] Currently, there's no distinct color scheme to visually distinguish between various appointment tags. It would significantly enhance the user experience to assign unique colors to each tag category.
Since we're creating a new column in DB, we have to manually setup modified_at values to created_at column initially, to keep the values proper. There on, the code will take care.
Description
As part of this PR, I've:
added color codes to status badges
added feature such that no of new appointments are shown in All, Emergency and Normal tabs for the current logged in admin.
When an admin logs in, if there are any new appointment request, a toast is triggered to show the number of new appointments to work on.
The new appointments are highlighted on the dashboard to inform the admin. The highlight goes away when the admin clicks and views the appointment.
If an admin is already logged in and a new appointment request is made, the dashboard updates in realtime highlighting the new request and a toast notification is triggered to inform the admin.
Removed the separate API calls for each type of appointment. Now, we have only one API call and the rest is taken care by the code.
Added modified date column to the DB
Updated the code such that the appointments in the Scheduled and Cancelled Tabs are sorted by modified date column as it seems more logical.
Related Issue
Closes #120 and #115
Acceptance Criteria
Type of Changes
Updates
Before
After
https://github.com/Full-Stack-Collective/connectient/assets/27571141/39e946fc-2a9d-4693-bf77-e49c2f6e2ea5
Note for release in production
Since we're creating a new column in DB, we have to manually setup
modified_at
values tocreated_at
column initially, to keep the values proper. There on, the code will take care.