Appointments+ service list dropdown filter to hook

Hello,

Just wondering if someone knew what filter, if any, that I can hook onto to limit the services that get displayed in the appointments page in the front end, but, doesn't effect the display services in the backend (edit appointments page, service provider tab, etc). I still need the backend to list all services.

You see I have a particular requirement to not display some services in the front end that matches a service i've flagged in my post_meta table.

Thank you,

Tin

  • Vinod Dalvi

    Hi Tin,

    I hope you are well today and thank you for your question.

    You can customize the service list dropdown by using the app_services filter declared as following in the below appointment plugin file on line number 1220.

    wp-content/plugins/appointments/includes/class_app_shortcodes.php

    $services = apply_filters( 'app_services', $services );

    Alternatively you can hide the specific option from the services dropdown in the front end by developing custom CSS code. I can help you to develop such CSS code if you share your appointment page URL.

    Best Regards,
    Vinod Dalvi

  • hoangker

    Hi @Vinod,

    Can you show me how to hide, for example, two services from the front end using CSS?

    <select name="app_select_services" class="app_select_services">
       <option value="2" selected="selected">Women's Cut</option>
       <option value="3">Children’s Cut</option>
       <option value="7">Foils/creative Colour</option>
       <option value="8">Hair Extension</option>
       <option value="9">Lip     </option>
       <option value="10">Updo’s</option>
       <option value="11">Chin</option>
       <option value="12">Eyebrows</option>
       <option value="15">Texture (perms)</option>
       <option value="16">Specialty Texture</option>
       <option value="17">Men’s Texture</option>
       <option value="22">Bridal updo’s</option>
       <option value="23">Blowdry and Styling</option>
       <option value="24">Blowdry and Curls</option>
    </select>

    Very much appreciated. Than i don't need to go into .php files.

    Thanks,

    Tin

  • Vinod Dalvi

    Hi Tin,

    I am not sure which two services you want to hide from the dropdown but from your shared screenshot it seems you want to hide the service "Texture (perms)" which you can do by adding the following CSS code in the Additional css Rules option of Appointments+ settings on the following path.

    Admin Area -> Appointments -> Settings -> General -> Display Settings

    .app_select_services option:nth-child(9) {
    display: none;
    }

    You can hide other drop down options by using above same code and just change the 9 value with the position of that option in the drop down list from top to bottom.

    Best Regards,
    Vinod Dalvi

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.