Hide the count of spaces left from time slots in Woocommerce Bookings

935 Views Asked by At

I am using Woocommerce Bookings. When someone books for a certain date/time slot it then shows on the calendar for the next customer that for that specific date/time slot that there are (98 left). Is there any way of removing/hiding this information from the calendar? Any help gratefully received!

screen shot of calendar showing 'tickets left'

1

There are 1 best solutions below

0
On BEST ANSWER

The following will hide the count of spaces left from hour slots:

add_action('woocommerce_single_product_summary', 'hide_slot_count_spaces_left', 25 );
function hide_slot_count_spaces_left() {
    global $product;

    if( $product->is_type('booking') ) {
        ?><style> small.booking-spaces-left{ display:none !important; }</style><?php
    }
}

Code goes in functions.php file of your active child theme (or active theme). Tested and works.