mmatin2017
mmatin2017

Reputation: 1

Rails 7 Flatpickr disable time and date

Currently I am working on a booking app and I am trying to disable times based on bookings already created. However, I only see documentation to disable a whole day/range of days. Is it possible to do something like this? And if not, are there libraries out there that can handle this with Rails 7? Thank you!

flatpickr_controller.js

Currently supported:

 disable: [
        {
            from: "2023-10-10",
            to: "2023-10-10"
        },
       
    ]

My requirement:

 disable: [
        {
            from: "2023-10-10 1:00 PM",
            to: "2023-10-10 2:00 PM"
        },
       
    ]

Upvotes: 0

Views: 96

Answers (1)

Dedy Puji
Dedy Puji

Reputation: 625

i don't think they have that feature yet, CMIIW

https://github.com/flatpickr/flatpickr/discussions/2841

Upvotes: 0

Related Questions