Skip to content

Commit d4be65e

Browse files
Automatically set the appointment color based on the service selection
1 parent da6d017 commit d4be65e

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

‎assets/js/components/appointments_modal.js‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,6 +365,10 @@ App.Components.AppointmentsModal = (function () {
365365
return Number(availableService.id) === Number(serviceId);
366366
});
367367

368+
if (service?.color) {
369+
App.Components.ColorSelection.getColor($appointmentColor, service.color);
370+
}
371+
368372
const duration = service ? service.duration : 60;
369373

370374
const startDateTimeObject = App.Utils.UI.getDateTimePickerValue($startDatetime);

0 commit comments

Comments
 (0)