search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

2 rows for one resource

Related article: Angular 6 Restaurant Table Reservation (PHP/MySQL)
Asked by fradega
5 years ago.

Please help me how to create scheduler for I have to correspond each one of the vehicle to 2 rows: reservation and itinerary, which both of them must not be to the same time

following the detail:

table 1: vehicle
vehicle_id
vehicle
capacity
status

table 2: reservation:
reservation_id
start
end
status
vehicle_id

table 2:
itinerary_id
datej
pickup
drop
task
vehicle_id

Answer posted by Dan Letecky [DayPilot]
5 years ago.

It is possible to display two rows for each resource:

1. The resource id needs to be unique. This can be done by prefixing a certain string to the resource id, e.g. "R" + id for reservations rows, "I" + id for itinerary rows.

See also:
https://api.daypilot.org/daypilot-scheduler-resources/

2. In order to display the reservation and itinerary items in the correct row, the "resource" property of the event object needs to match the row id. That means you'd prefix itinerary_id with "I" and reservation_id with "R" when saving it to "resource" property.

See also:
https://api.daypilot.org/daypilot-scheduler-events-list/

Comment posted by fradega
5 years ago.

Hi,
I m not sure to understand how to manage it but I will try to...
thank you very much for your prompt answer, I really appreciate indeed,

Franckie

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.