Appointments+ custom duration

I was provided this code to add in mu-plugins that allows me to have 20 and 15 minutes appointments.

add_filter( 'app-time-min_time', function(){
return 5;
} );

But the time slots displays now as if the service duration was 5 minutes.

I have only one service provider, what I would like to achieve is, having services with 20 and 15 minutes.

So for example, if 1 hour time slot(12:00-1:00) is booked from a service, a 2nd appointment booked for a 25 minutes service, I want the third appointment booked for another 1 hour service to start at 1:25, not the normal 1 hour slot.

  • Patrick
    • Support Monkey

    Hi there mpress

    I just saw this question while browsing around tickets and thought I could help out. I believe the Tetris Mode addon in Appointments+ would help you get this done.

    To give you an example on my test site, I have added the code to allow for a 5-minute Time Base, and have created 3 services; one with a duration of 15 minutes, one with a duration of 20 minutes, and a 3rd with a duration of 60 minutes.

    With the Tetris Mode addon active, you can see on the following example that the schedule of available time slots automatically adjusts itself according to the appointments already booked:
    http://appointments.pcwriter.net/Make-an-Appointment/

    You can see the effect especially by selecting the 23rd as the date for an appointment, where I have already booked a few slots to test it.

    Please do let us know if this has helped resolve your issue, or if your still need assistance getting this to work for you. :slight_smile:

    • mpress
      • Code Wrangler

      Hi Patrick ,

      before going to my site, I was trying to make some appointments on your test site, just to see how it works.

      I got some refresh issues.
      Imagine a customer chooses an appointment of 15 mins but them realizes it is better to choose one for 60 min. Time table refreshes in a way that I still see there the time slots for the 15 min app.
      If I refresh everything, it goes ok, but a "normal" visitor will not always think about refreshing pages.

      Does it also happens to you?

      Cheers

      • Patrick
        • Support Monkey

        I think maybe you had just forgotten to click the "Show Available Times" button again after switching to a different service.

        So to make it easier to see how things work with the Tetris Mode addon, I've removed the Service Provider selectbox (there's only one anyway) and have added the autorefresh parameter to the Services shortcode so you don't have to click any buttons to see the schedule for the selected service.

        I also added a screenshot of the confirmed appointments on the 23rd so you can see how the different service durations that have been booked affect the schedule.

        :slight_smile:

        • mpress
          • Code Wrangler

          Thanks Patrick Patrick ,

          This is the waywe have settings for this site. Service provider selectbox is hidden (cause there is only one service provider) and autorefresh parameter is active.

          It looks like it is working the way we need/wanted.

          I will check with site's owner and will be back if necessary :slight_smile:

          Cheers

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.