I’m new here, in the sense that this is the first question I ask.
I have a reservation component comprising, among other things, three selectors: a first datepicker to indicate the start date of the reservation, a selector with pre-defined reservation durations and a second datepicker which must indicate the end date of the reservation.
When the first datepicker indicates a date and the reservation duration selector has a selected value (for example 1 hour of rental), the second datepicker must automatically display the correct date and time of the end.
Do you have any idea how I can do this in javascript? I specify that the project is based on VueJS2 and the datepicker is vue2-datepicker.
Thank you for help me !
I specify that I am new to algorithms, so I do not know a solution to my problem. I only want to learn.