This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Do NOT include the opening php tag, only copy the code below to functions.php file | |
if ( class_exists( 'WC_Appointments' ) ) { | |
// Default Calendar view: 'day' or 'month' | |
add_filter( 'woocommerce_appointments_calendar_view', 'appointments_default_view' ); | |
function appointments_default_view() { | |
$default_view = 'day'; | |
return $default_view; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_theme_support( 'woocomerce-appointments-show-discounted-slots' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Do NOT include the opening php tag, only copy the code below to functions.php file | |
add_filter( 'woocommerce_appointments_gcal_sync_statuses', 'gcal_sync_unpaid_statuse' ); | |
function gcal_sync_unpaid_statuse( $sync_statuses ) { | |
//* Sync with unpaid appointments | |
array_push( $sync_statuses, 'unpaid' ); | |
return $sync_statuses; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$array( | |
'id' => '', | |
'sku' => '', | |
'show_title' => 1, // use 1 or 0 | |
'show_rating' => 1, // use 1 or 0 | |
'show_price' => 1, // use 1 or 0 | |
'show_excerpt' => 1, // use 1 or 0 | |
'show_meta' => 1, // use 1 or 0 | |
'show_sharing' => 1 // use 1 or 0 | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Do NOT include the opening php tag, only copy the code below to functions.php file | |
//* Remove scheduling form | |
add_action( 'wp_head', 'bizzwoo_remove_appointment_form', 0 ); | |
function bizzwoo_remove_appointment_form() { | |
global $wc_appointment_cart_manager; | |
remove_action( 'woocommerce_appointment_add_to_cart', array( $wc_appointment_cart_manager, 'add_to_cart' ), 30 ); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Modify the color styles of the WooCommerce Appointments booking form. | |
Add any/all of these styles to your theme's custom CSS, but be sure to change | |
the color hex codes to your choice. They're all default here. | |
*/ | |
/* Booking form wrapper */ | |
.wc-appointments-appointment-form { | |
background-color: #fff; | |
border: 1px solid #ddd; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Do NOT include the opening php tag, only copy the code below to custom_functions.php file | |
add_filter( 'bizz_coupon_filter', 'custom_coupon_filter' ); | |
function custom_coupon_filter( $coupon_post ) { | |
$coupon_post['type'] = 'percentage'; // 'percentage', 'fixed_unit', 'fixed_block' | |
$coupon_post['amount'] = '10'; | |
$coupon_post['car'] = array( 'all' ); // accepts array of vehicle ID's or 'all' for all vehicles | |
$coupon_post['extra'] = array( 'all' ); // accepts array of extra ID's or 'all' for all extras |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Do NOT include the opening php tag, only copy the code below | |
add_filter( 'coupon_filter', 'custom_coupon_filter', 10, 7 ); | |
function custom_coupon_filter( $return, $car_id, $carhire_cookie, $days_array, $pricing_posts, $coupon_post, $opt_s ) { | |
// count days | |
$count_days = ( $isobject==1 ) ? $carhire_cookie->count_days : $carhire_cookie['count_days']; | |
// minimum 3 days hire |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Do NOT include the opening php tag, only copy the code below | |
add_action( 'bizzthemes_send_notification_shortcut', 'disable_customer_notification', 10, 3 ); | |
function disable_customer_notification( $status, $customer_email, $subject, $body, $headers ) { | |
// Stop customer email notifications | |
if ( $status == 'customer' ) { | |
return ''; | |
} |
NewerOlder