WPSlash

How to set Pickup Only on WooFood

Thursday September 5, 2019

With these few lines of code you can disable Delivery Option on WooFood for WooCommerce and set the pickup option as default. Copy and paste the following two snippets to your functions.php inside your Theme or Child Theme folder

You will have to use the woofood_order_types_filter filter to return an array including only the pickup option like the following example

add_filter( 'woofood_order_types_filter', 'custom_hook_pickup_only' );
function custom_hook_pickup_only( $order_types ) {
   $new_order_types = array('pickup'=>esc_html__('Pickup', 'woofood-plugin'));
   return $new_order_types;
}

You will need also to change the default order type , so you need to use also the woofood_default_order_type_filter like on the following snippet

add_filter( 'woofood_default_order_type_filter', 'custom_hook_pickup_as_default' );
function custom_hook_pickup_as_default( $default_order_type ) {
   $new_default_order_type = "pickup";
   return $new_default_order_type;
}

If you are still not able to do it yourself , feel free to submit a ticket here 

Leave a Comment

Your email address will not be published. Required fields are marked *

Related Articles

WooFood

How to Disable Coupons for Delivery Orders in WooCommerce

If you’re running a WooCommerce-powered restaurant or food delivery service, you might want to restrict certain coupon codes for delivery orders while keeping them valid for pickup orders. This ensures better control over discounts, prevents misuse, and improves your store’s pricing strategy. Why Restrict Coupons for Delivery Orders? Offering coupons is a great way to attract customers, but in food […]
June 20, 2023
WooFood

How to Automatically Re-Enable Disabled Products in WooFood Once a Day

If you’re running a WooCommerce-powered restaurant ordering system using WooFood, you might have products that automatically get disabled due to stock limits or availability settings. To ensure a smooth customer experience, you can automate the re-enabling process using a scheduled WordPress cron job. This method allows you to reset all product availability once a day, ensuring your menu stays active without manual intervention. Why […]
March 8, 2023
WooFood

How to Add Live Product Search to WooFood in WooCommerce

Enhancing the user experience of your WooCommerce-powered restaurant ordering system is crucial, and adding a live product search feature can significantly improve navigation. This feature allows customers to quickly find food items in your WooFood-powered menu without manually browsing through categories. In this article, we’ll show you how to integrate a live product search above the accordion menu in WooFood using a simple jQuery script and PHP snippet. […]
December 29, 2022