Scheduler Readonly Slots
|Product||Scheduler for Blazor|
I want to define readonly time slots in the Scheduler. The user should not be able to create or edit appointments at those times. This is useful for breaks (no appointments at lunch time) or holidays. How to achieve that?
You can implement custom validation method to check if an appointment is valid and handle the Scheduler CRUD events to update the data only if the appointment meets the desired criteria.
Additionally, you can include some custom CSS styles to visually mark the corresponding slots as readonly (for example, set a different background color).
You can find an example here: Scheduler - Readonly Slots.
At the time of writing (UI for Blazor version 2.30), the Scheduler does not expose an OnCellRender event to add custom CSS classes to time slots. The example calculates the readonly slot indexes manually and uses those indexes in a CSS rule. Once
OnCellRenderis available, such customizations will be a lot easier.