Join our new community forum for support & discussion

Join Now

Home Support Extensions Bookings booking attributes

booking attributes

  • Author
    Posts
  • VolumeR

    Hello,

    How can I change or delete some booking attributes?

    For example, I don’t need “Booking Offset” field, how can I delete it?

    Thank you!

    ihor developer

    Hi,
    It’s possible to hide/remove the custom booking attributes, but customizing the built-in ones requires a custom code snippet. Please let me know if this is the only field you want to hide and I’ll post the code snippet.

    VolumeR

    Hello,
    I wold like to hide following attributes:
    – Booking Offset
    – Booking Window

    By the way, it’s still not possible to block periods in the agenda as in your demo video, the buttons are not there. You told that the next update will fix it, how can I update the Booking extension?

    ihor developer

    Please try using this PHP snippet:

    add_filter(
    	'hivepress/v1/models/listing/attributes',
    	function( $attributes ) {
    		if ( isset( $attributes['booking_offset'] ) ) {
    			$attributes['booking_offset']['editable'] = false;
    			$attributes['booking_window']['editable'] = false;
    		}
     
    		return $attributes;
    	},
    	1000
    );

    Blocking/unblocking is available for date-based bookings, but it’s not available for time-based bookings yet, we’re working on it and will add this feature as soon as possible.

    VolumeR

    Thank you!

Viewing 5 posts - 1 through 5 (of 5 total)

New Reply

This forum has been archived and is no longer accepting new posts or replies. Please join our new community forum for support & discussion.