WP Manifestindependent plugin directory
manifest / events / jet-appointments-adults-children-inputs

Jet Appointments - Adults & Children Inputs

jet-appointments-adults-children-inputs

by Crocoblock · github.com/mjhead/jet-appointments-adults-children-inputs

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/mjhead/jet-appointments-adults-children-inputs/archive/refs/heads/main.zip

JetAppointmentsBooking. Allow Adults & Children fields in the appointment form

This plugin allows you to add seprate fields for Adults count and Children count and book total number of slots by the sum of values in these 2 fields.

Result example:

image

How it works:

  1. This plugin is JetAppointmentsBooking addon, so first of all you need JetAppointmentsBooking plugin installed.
  2. Also it supports only JetFormBuilder (not JetEngine legacy forms), so also you need JetFormBuilder plugin installed.
  3. Separate fields for adults and children means single time slot could be booked multiple times. So you need to enable Manage Capacity option of JetAppointmentsBooking plugin. Also you need option User Can Manage Booked Capacity to be disabled, because you'll manage capacity with adults and children fields.
image
  1. You need to add Adults and Children fields into the form manually. Optionally you can put them int the conditional block and show only user will select the slot in the calendar.
  2. The last thing - you need to specify 4 properties to connect form and this addon - Adults field, Children field, Price per adult, Price per child. More detailed instructions on this below.

Setting up the plugin properties

You can set up the plugin properies in the 2 ways

To manage this with WordPress options you can create JetEngine Option Page. Here is the setup of the page

image image

And the result

image

The important thing here are:

  • Slug of the page must be exactly jet_apb_ac
  • Fields storage type must be set to Separate
  • Add prefix for separate options must be enabled
  • Fields slugs must be exactly - adults_field, children_field, adults_price, children_price

Price setup

Separate options for the price are needed to make this part compatible with WooCommerce integration of JetAppointmentsBooking and set correct price for the checkout. If you need to show total price in the form, you can use Calculated field and add these values directly into it, for example like this:

image

And the result

image