Hello - with the RentalHive, I’ve installed the Opening Hours extension. On the listing page, the hours of operation appear on the right-hand side of the page between the booking module and above the host module.
Is there a way to move the hours of operation information above the booking module so it shows up between the primary attributes block and the booking block?
OR
To have it be moved into the left-hand column of the page (so it’s displayed below the secondary attribute block)?
Thanks so much! I’m so grateful for having found this theme!!
Thank you for your feedback. We are glad that it is useful for you
Please try this PHP snippet to show up between the primary attributes block and the booking block
add_filter(
'hivepress/v1/templates/listing_view_page',
function ($template){
return hivepress()->helper->merge_trees(
$template,
[
'blocks' => [
'listing_opening_hours' => [
'_order' => 15,
],
],
]
);
},
1000
);
Please try this PHP snippet to show it below the secondary attribute block
add_filter(
'hivepress/v1/templates/listing_view_page',
function ($template){
return hivepress()->helper->merge_trees(
$template,
[
'blocks' => [
'page_sidebar' => [
'blocks' => [
'listing_opening_hours' => [
'type' => 'content',
],
],
],
'page_content' => [
'blocks' => [
'custom_listing_opening_hours' => [
'type' => 'opening_hours',
'model' => 'listing',
'_order' => 55,
],
],
],
]
]
);
},
1000
);