Hi, how can I make Check-in and Check-out time optional in Listing? Thank you.
Hi,
Please use these PHP snippets (How to add custom code snippets - HivePress Help Center):
add_filter(
'hivepress/v1/models/listing/attributes',
function( $attributes ) {
if ( isset( $attributes['check_in'] ) ) {
$attributes['check_in']['edit_field']['required'] = false;
}
return $attributes;
},
1000
);
add_filter(
'hivepress/v1/models/listing/attributes',
function( $attributes ) {
if ( isset( $attributes['check_out'] ) ) {
$attributes['check_out']['edit_field']['required'] = false;
}
return $attributes;
},
1000
);
I believe this will be useful to you.
1 Like
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.