Skip to content

WooCommerce Bookings

WooCommerce Bookings support

Addon groups on a bookable product render the same way they do on a simple product. The plugin does not add booking-aware pricing or scheduling.

What “integrates with Bookings” means here. Compatibility is that addons work normally on bookable products. There is no is_type( 'booking' ) check, and no booking-date, resource, or person-aware pricing anywhere in the plugin.

What the plugin does

BookingsIntegration only instantiates when class_exists( 'WC_Bookings' ). Its entire behavior: it hooks the existing saue_before_render_product_addons action and re-fires it as saue_bookings_before_product_addons, passing the same $product_id.

saue_before_render_product_addons fires for every product that has addons, of any product type. The Bookings-named hook is not filtered to bookable products either. Addons on a bookable product use the same render path as addons on a simple product — that is the entire compatibility.

What it does not do

  • No check that the product is a booking product.
  • No reference to WC_Booking or WC_Product_Booking.
  • No pricing that depends on the selected booking date, resource, or person count.
  • No booking-form field integration or slot-aware validation.

Extension point

If you need booking-specific behavior, hook saue_bookings_before_product_addons yourself. It exists so you can add that logic — not because the plugin already has any. Remember it fires for any product with addons while WooCommerce Bookings is active, so check the product type in your callback.

/**
 * Add your own booking-specific logic before addons render.
 * This hook is registered only when WooCommerce Bookings is active,
 * but it fires for every product that has addons — not only bookings.
 */
add_action( 'saue_bookings_before_product_addons', function( $product_id ) {
    $product = wc_get_product( $product_id );

    if ( ! $product || ! $product->is_type( 'booking' ) ) {
        return;
    }

    // Your booking-specific logic here (enqueue a script, inject

    // markup, or read booking form state). The plugin does not

    // calculate addon prices from booking dates, resources, or persons.

} );

Hook signatures: Hooks & Filters. WPML string translation (separate from Bookings): WPML support.