Appointments+ showing different available starting times for different services.

I have currently have 2 appointments scheduled for 1/14. One hour slot at 1:00 and one 15 minute slot at 2:15. I have 15 minutes padded AFTER all services and none for providers. If I look at my calendar and choose a service that is 15 minutes, it shows availability at 2:30 (padding not kicking in for that 2nd appointment). If I select a service that is an hour long, it shows availability at 3:30. Seems to me availability should show up at 2:45 no matter what since I only have AFTER padding configured. What's the deal?

  • Tyler Postle
    • CGO

    Hey Brightfuture,

    Hope you're doing well today!

    This seems to be working on my install. It will add the padding to the entire calendar so not only for Appointments as they are booked. Can you grant support access so I can have a closer look at your Appointments settings?

    You can grant support access via WPMU DEV > Support > Support Access > Grant Access.

    https://premium.wpmudev.org/manuals/wpmu-dev-dashboard-enabling-staff-login/

    It could also be because you have 2 service providers. If either of them don't have a scheduled service, then it will give them the next earliest available time. Try adding the padding after the service providers instead of the services since the padding is the same for all services.

    Look forward to hearing back!

    Cheers,
    Tyler

  • Tyler Postle
    • CGO

    Hey Brightfuture,

    I just changed the way the time calculus works by turning on the Durations add-on and changing it to the legacy option as you can see in my attached screenshot.

    Can you check the service times now and let me know if they are how you want them to look? I checked with the 1 hour service and it's showing 2:30 now instead of 3:30 :slight_smile:

    Talk to you soon.

    Cheers,
    Tyler

  • brightfuture333
    • Site Builder, Child of Zeus

    Hi Tyler,
    Thank you for looking into this.
    I see that all services are now showing 2:30 available, but that still isn't right. Since I have a 15 minute time slot entered at 2:15 and a 15 minute padding, the next available apt should be at 2:45. It seems that setting did something, but also showed a lot of non-work hours times (although busy or not possible) and I really don't like seeing that.
    I'm kinda tempted to lost the padding and just add 15 minutes onto each of my services, although I like the idea of padding (as long as it works right) a lot better!

  • brightfuture333
    • Site Builder, Child of Zeus

    Ugh. I've tried to eliminate all complications by turning off padding (and adding the padding to the service itself) and that add-in you added, and also unchecking the "dummy" field in my dummy service provider, but this thing is still a mess. Honestly, seeming useless. If I have a 75 minute appointment scheduled at 1:00, why in the world would it not show an available appointment until 3:00 when you have a service selected that is 60 minutes. This is so frustrating. :slight_frown:

  • brightfuture333
    • Site Builder, Child of Zeus

    Seems to me it has something to do with the length and the way it calculates available timeslots for appointments thereafter, however, it should just show availability at 15 minute intervals (because that's what I have set). So whether I choose a 30 minute session or a 1:00 session, if my schedule is clear as of 2:15, availability (for any service) would look like this:
    2:15, 2:30, 2:45, 3:00, 3:15, 3:30....

    How do you set it to do that?

  • Tyler Postle
    • CGO

    Hey Brightfuture,

    I totally see what you mean here. Been testing it on my own sandbox and can replicate your issues. Services don't seem to always respect the padding. As for the 15 minute intervals, the padding is causing the issue there so if you turn off the paddings add-on and keep the setting to "minimum time based duration" like I set it to above then it will show all in 15 minute intervals.

    I realize this would mean that your clients will see the appointments as being 15 minutes longer than they are so I think a possible workaround in the meantime that we could provide is making it so your displayed "duration" of appointments in the checkout form is -15 minutes. This way you can keep the additional 15 minutes on each of your services, but in the checkout form it will still show the real duration to your clients. Would that work?

    I'm also going to discuss the padding with one of our developers as I really don't think it is working the way it should be either.

    Look forward to hearing back! Either myself or the developer will reply back here too once they get a chance to investigate this further.

    Cheers,
    Tyler

  • brightfuture333
    • Site Builder, Child of Zeus

    Hi Tyler,
    I can live with that workaround of having appointments show -15 in the checkout. I do put the time intended in ()'s in the service name, but I think its confusing to show 2 different lengths.
    I appreciate you also talking to the developer about getting all that fixed in an update.
    I can see that setting the duration to "minimum time based duration" displays the 15 minute intervals, but I sure do wish it didn't show all those times that are not part of my scheduled work day! It's a mess, and it also takes a VERY long time to load the page each time I select a different service :slight_frown:.
    I think I'd rather have fewer spots showing and less time to load... but I'd really like to see it fixed where it only showed times within scheduled work hours.

    Appreciate your help!

  • pxwm
    • WP Core Meltdown

    Hi @Tyler Postle - I hope you don't mind me suggesting a possible solution

    Hi @brightfuture333,

    If I've understood your requirements correctly then you may wish to try the following:-

    1) Set the padding for each Service to 0. When you have clicked update/save just check to make sure the new settings have been saved. I found you had to do this twice.
    2) Then DeActivate the Padding Add-on
    3) Add 15mins to each of your Services.
    e.g. For your 60mins Service make this 75mins and your 15mins Service make this 30mins

    Then add the following code to your ACTIVE themes functions.php file
    I always add bespoke code at the bottom of the functions.php file directly above the php closure tag (?>:wink:, that is if there is one.

    IMPORTANT - Take a backup of your site so you have an option to revert

    function modify_duration_text( $text, $duration ) {
    	global $appointments;
    	return ($duration - 15) . ' minutes';
    
    }
    add_filter('app_confirmation_lasts', 'modify_duration_text', 10, 2);

    This will then show a 75m or 15min availability slots in the calendar but when the client/customer books an appointment slot it will show either 60mins or 15mins duration for the Service booked.
    However if you book an appointment it will allocate a 75min slot and 15min slot so effectively giving you the 15min padding after the Service.

    I hope this helps and please let me know if this works for you.

    Regards
    SteveB

  • brightfuture333
    • Site Builder, Child of Zeus

    Hi SteveB,
    Thank you for the code to make the changes to my appointment program.
    I am going to do this for sure.
    I'm gone most of today and going out of town tomorrow, so I might not have a chance to get to it right away, but I will take care of this soon and let you know how it goes.
    Thanks again.

  • pxwm
    • WP Core Meltdown

    Hi @brightfuture333

    If I've understood your requirements correctly and having reviewed your site at: http://bright-future.net/wpress/newsletters/make-an-appointment/

    Is it possible you could provide a screenshot of your 'General' tab in Settings just for the 'Time Settings' section.

    I ask because on my demo site I have the 'Time Base' set to 15mins and the 'Time slot calculus method' set to 'Minimum time based appointment duration calculus (legacy)' and in my calendar on the front end it shows 15min time slots.

    Could you also confirm if the website I reviewed at: http://bright-future.net/wpress/newsletters/make-an-appointment/ is correct as I noticed that the available time slots overlaps the calendar.

    Regards
    SteveB

  • pxwm
    • WP Core Meltdown

    Hi @brightfuture333

    Many thanks for the confirmation.
    Having reviewed your attached pdf I think I understand your requirements and would appreciate if you could confirm if I have this correct.

    You would just like the calendar to display the time slots for the work schedule/Working Hours for each Service Provider.
    e.g. For your example you only want to display 1pm to 6pm and none of the other times.

    Am I correct?

    If so I think I have a solution.

    Regards
    SteveB

  • pxwm
    • WP Core Meltdown

    Hi @brightfuture333,

    Could you please try the following that I've tested on my demo site and it seems to display as per your requirements:-

    Suggest you take a backup of the site so you have a fallback
    Log-in to your Wordpress dashboard as Admin
    Select A+ >Settings >General tab
    Scroll down to the 'Display Settings' section
    Then in this section locate the field 'Additional css Rules'

    Then add the following css code on a new line:-

    .app_timetable .notpossible {display: none !important;}

    If there is already some custom css code in this field then make sure you add on a new line

    Then scroll to the bottom and click 'Save Settings'

    Then go to your site and refresh the Appointments page and check.

    Please let me know if this works.

    Regards
    SteveB

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.