Hi everyone,
I'm developing an app for managing parking spot reservations. Here's the situation:
User Roles:
Time Blocks: To simplify the process, Priority Users select from predefined time blocks instead of specific times:
I have an Enum column [Time Block] with these options.
The issue: I want the calendar view to display events in the correct time intervals based on the selected [Time Block], so Temporary Users can see available spots accurately in the calendar (not just as all-day events).
I'm having trouble calculating [Start Time] and [End Time] (both of type DateTime) based on the [Time Block] selection. I've tried the following expression in the [Start Time] column:
And similarly for [End Time], but with the appropriate end times. However, the [Start Time] and [End Time] aren't calculating correctly, and events are not appearing in the calendar at the correct timesโthey either show as all-day events or don't display in the hourly slots.
What I've checked:
Could someone please guide me on how to correctly calculate [Start Time] and [End Time] based on the [Time Block] selection, so that events display in the calendar view during the correct time intervals?
Any help would be greatly appreciated!
Thank you!
Barbara
Start Time would be:
(
DATETIME([Release Date])
+ SWITCH(
[Time Block],
"Morning", "008:00:00",
"Afternoon", "012:00:00",
"Whole Day", "008:00:00")),
""
)
)
User | Count |
---|---|
18 | |
9 | |
8 | |
5 | |
5 |