Add service availability configuration with weekly scheduling#2145
Add service availability configuration with weekly scheduling#2145gabriel090 wants to merge 5 commits intoopenmrs:mainfrom
Conversation
|
@gabriel090 Please add a ticket in the openmrs Jira for tracking purposes and future reference. Thanks |
1 similar comment
|
@gabriel090 Please add a ticket in the openmrs Jira for tracking purposes and future reference. Thanks |
|
please resolve the conflict in your PR code |
Specifically, we recently migrated to use Workspace V2. @gabriel090 Please refer to the migration guide on what needs to be changed. |
I second this. Looks like the backend actually supports the feature you're working on. That said, we have not implemented this on the frontend because we haven't needed it. Has that changed? If so, a JIRA to document the requirements would be good. |
chibongho
left a comment
There was a problem hiding this comment.
Not a thorough review; just some initial comments.
packages/esm-appointments-app/src/form/appointments-form.workspace.tsx
Outdated
Show resolved
Hide resolved
packages/esm-appointments-app/src/workload/monthly-view-workload/monthlyWorkCard.tsx
Outdated
Show resolved
Hide resolved
packages/esm-appointments-app/src/form/service-availability-form.test.tsx
Outdated
Show resolved
Hide resolved
packages/esm-appointments-app/src/form/service-availability-form.test.tsx
Outdated
Show resolved
Hide resolved
Thanks for the feedback! I've migrated the service availability form to use Workspace v2 architecture. The changes include:
|
Yes, the requirements have changed. This feature is now needed to manage appointment capacity and prevent overbooking at our facilities.
|
- Migrated service availability form to Workspace v2 architecture - Removed inline styles (opacity) in favor of CSS classes - Optimized tests: removed clearAllMocks, replaced waitFor with findBy - Removed comments and unused code from SCSS and TypeScript files
packages/esm-appointments-app/src/hooks/useAppointmentsCalendar.ts
Outdated
Show resolved
Hide resolved
Great! Please file a ticket in Jira. |
Requirements
Summary
Add a new "Configure Service Availability" feature that allows administrators
to set maximum appointment limits at both the service-level and per-day level through
weekly schedules.
Features Added:
1. Set up for Maximum Limit for All Days
Purpose: Set a default maximum appointment limit that applies to all days of the week for a service.
How to Use:
Behavior:
maxAppointmentsLimitfield of the appointment servicedaily_setup.mp4
2. Booking When Maximum Limit is Reached
Current Behavior:
maxAppointmentsLimitfield is configured and saved, but not enforced during bookingExpected Behavior (To Be Implemented):
When a user attempts to book an appointment:
maxAppointmentsLimit.daily_booking.mp4
3. Weekly Setup for a Service
Purpose: Configure different availability schedules and limits for each day of the week.
How to Enable:
Selecting Days:
Step 1: Check desired days
Day-Specific Maximum Limits:
maxAppointmentsLimit.weekly_setup.mp4
4. How It Works When the Max Limit for a Specific Day is Reached
Current Implementation:
weeklyAvailabilityarrayweekly_booking1.mp4
Screenshots
Related Issue
Other