Hello,
I manage an app for parking booking and want to show the booking slots for each parking place. Something like that:
What I've done can show only the slot for the first booking but I want to show red zone for all the slots of the day per place.
- I make a container with 11 Textfield to show the hours
- I make a gallery with the bookings of the day as datasource
- Field of this gallery:
- Title with the name of the place
- Rectangle with properties:
- X =
DateDiff(DateTime(Year(DatePicker.SelectedDate), Month(DatePicker.SelectedDate), Day(DatePicker.SelectedDate), 7, 0, 0),LookUp(MyBookingDayCollection,Code_Parking=ThisItem.Numero).startHour,TimeUnit.Minutes)*1.5
The size for 30 minutes is 45, that's why I put *1.5
Width =
DateDiff(LookUp(MyBookingDayCollection,Code_Parking=ThisItem.Numero).startHour,LookUp(MyBookingDayCollection,Code_Parking=ThisItem.Numero).endHour,TimeUnit.Minutes)*1.5
For example the parking place 45 is booked 2 times this day:
And with my code, I see only the first slot in red:
I had the idea to make it with a horizontal gallery with 22 rectangles into the vertical gallery but cannot achieve it simply.
Could you help me?