roggervalf / react-appointment-picker

React component to pick an appointment
MIT License
10 stars 13 forks source link

How can i start the schedule earlier than 9AM? #7

Closed vickyintokyo closed 4 years ago

vickyintokyo commented 4 years ago

Hi Roger, Thanks for the component. It really fits the bill for my app. Below is not an issue but more of requests.

  1. Is it possible to pass the start time of the schedule via parameter? not always starting at 9
  2. Is it possible to have prev and next button, with which user can view data for next week or prev week?

Thanks much Vikram

roggervalf commented 4 years ago

Hi @vickyintokyo:

  1. For setting a different starter time, you should pass an initialDay with a date with time, example: initialDay={new Date("Fri May 04 2018 17:00:00 GMT-0500")}
  2. You could try pasing different days props when clicking on those buttons, should be changed. Let me know how works it and thank you for comment your doubt.
vickyintokyo commented 4 years ago

@Rogger794 Perfect. Thank you so much quick turnaround.

  1. Understood. This was easy.
  2. I see, thats what my first thought. So I think i need to right extra code to handle the user actions on Prev and Next button. Let me work on it. let me know if you have time and planning to handle it as extension to your component. Again thanks much for the component. Stay safe !!
roggervalf commented 4 years ago

Also I used to use this component, this one could work with react-appointment-picker together https://ant.design/components/pagination/

vickyintokyo commented 4 years ago

@Rogger794 Thank you so much. Let me close this issue.