It’s a common practice these days to book hotel rooms online. Sometimes while doing so, we notice that we cannot book the room for just one night. We have to book for a minimum of two (or more) nights. Sometimes, you are hosting a party and you need props. The vendors make you rent it for at least two days. So basically you have to rent or book an item for a minimum number of days. You can book more than the minimum, but it cannot be lower than the minimum.
In this post, we are going to learn how to book for a minimum number of days with the WooCommerce Booking & Appointment Plugin.
Book for minimum number of days with WooCommerce Booking & Appointment Plugin: Admin Experience
The first step will be creating your bookable product. You can do that from the Products -> Add Product link. On the same page, you would also find the Booking meta box that allows you to set up your bookable product. Then you have to do some general booking settings.
Under the “Booking options” tab, I have selected the Enable Booking Date. This option works only with multiple-day booking. So you will need to enable “Allow multiple day booking” setting.
The option Minimum Day Booking For Multiple Days should be enabled to set a minimum number of days for booking. I have set that the Minimum number of days to book for multiple-day bookings as “2”. So when a customer tries to make a reservation, they have to book for a minimum of two nights. The option Lockout date after X orders lets you give a maximum number of bookings you can do on a particular day. I have set that value as “60”. For a hotel room as my product, the lockout will depend on the number of such rooms available. Once all of these are booked, it should lock the bookings for hotel rooms. Hence, your lockout should depend on the number of your bookable products / units available.
A booking system must allow you to specify how much time in advance you want the customer to book the product.
The WooCommerce Booking & Appointment plugin allows you to do that by specifying the number of hours in the Advance Booking Period field. It is present in the Bookable Time Period tab.I have set it to “24” hours which means if you are trying to book today for today’s check-in, you won’t be able to do that. You will have the earliest check-in of 24 hours from today, which would be tomorrow.
The Number of Dates to choose lets you determine the maximum number of days from today which you want to allow booking for. In some cases, this could be a month (30 days) or even a year (365 days). I have set it to 365 days, which means the check-in calendar will have dated for a year from today to choose from.
Since you are booking hotel rooms, you might want to change the labels on the frontend accordingly. You can do that from Booking -> Settings -> Booking Labels. There are labels on product page, order received page, email notifications, cart and checkout page, so you have to make sure that you don’t miss out on any of these. Make changes wherever necessary and once that is done click on the “Save Changes” button. For hotel bookings, I have changed it to “Check-in date” and “Check-out date” on all the pages.
Once you have completed all these steps, unless you don’t have anything more to add, your WooCommerce Bookable product for the hotel rooms is ready.
Book for a minimum number of days with WooCommerce Booking & Appointment Plugin: User Experience
This is how the booking appears on the frontend when the product page is loaded and the date is selected respectively.
I selected the check-in date as 10th Sep. In the check-out calendar, 11th Sep appears disabled. Only the dates starting from 12th Sep were available for booking.
Note: The check-in calendar appears however in the above screenshot it’s hidden behind the check-out calendar.
Once you select the check-in and check-out dates, the “Add to Cart” button is visible. When you click on that button, the order is added to your cart and there is a button to “View your Cart”. On clicking that you are directed to the cart page which will show all the details of your order.
When on the cart page, unless you don’t want to update your cart, you can go to the checkout page by clicking on “Proceed to checkout” button.
The checkout page will show the booking details and the total amount for your order. You can place your order if everything seems fine. Checkout page gives you a preview of the actual order. Please ensure you check everything and then click on the “Place Order” button.
After placing your order, the final details are shown on the Thank You page. Email notifications are sent to the customer and the administrator with the details.
Enable Minimum day booking for all products
There is another way to enable minimum day bookings for all your products by default. You can do that by going to Bookings -> Settings and enabling Minimum Day Booking. This will apply to all products. So you do not have to go in each product & configure manually.
Conclusion
This setup shows how the minutest details of bookings are taken care with ease. Everything is similar to the usual hotel booking setup except for the minimum number of days option.
Having the ability to set the Minimum booking days for all products together is a huge plus.
It is also possible to use this setup with WooCommerce Variations. The above example was for Simple Products only.
Since this was a very simple setup as a first timer it will not take you more than 15 minutes to get the system up and ready.