How to reduce bookable product setup options?

We're shifting our Forum based support to a more dedicated support system!

We'll be closing our Forum support from 10th June, 2020 and move to Email Support assistance.

  • If you are a WCFM premium add-ons user, contact us- here
  • Want to know more before buying our add-ons? Send Pre sale queries- here
  • If you are a WCFM free user, please open a support ticket at WordPress.org
  • For WCFM App related queries, reach us- here
From now the forum will be read-only!

Multi Vendor Marketplace Plugin | WCFM Marketplace Forums WC Vendors How to reduce bookable product setup options?

Viewing 6 reply threads
  • Author
    Posts
    • #126483
      eritechdeveloper
      Participant

      There are a lot of options, which I am grateful for, but I would like to reduce it to the bare minimum at the start.

      How can I preset certain options, disable certain options for example, and rename certain titles? For instance, I want to preset bookings to be cancelled up to 24 hours, remove block cost, and rename Base cost to price. This is not the full list, but if you guide me on how to do these I am sure, I can figure out the rest.

      Thank you.

    • #126548

      Hello,

      I want to preset bookings to be cancelled up to 24 hours
      >> For this,

      add_filter('wcfm_wcbokings_general_fields',function($fields,$vendor_id){
      	$fields['_wc_booking_user_can_cancel']['dfvalue'] = 'yes';
      	$fields['_wc_booking_cancel_limit']['value'] = 24;
      	$fields['_wc_booking_cancel_limit_unit']['value'] = 'hour';
      	return $fields;
      },10,2);

      remove block cost, and rename Base cost to price
      >>For this,

      add_filter('wcfm_wcbokings_cost_fields',function($fields,$product_id){
      	$fields['_wc_booking_cost']['label'] = __('Price', 'woocommerce-bookings');
      	unset($fields['_wc_booking_block_cost']);
      	return $fields;
      },10,2);

      Add this above code to your child theme’s functions.php
      In case you do not have child theme then add code using this plugin – https://wordpress.org/plugins/code-snippets/

      Please be advised,before removing random fields for setup Booking product some fields are required field (https://docs.woocommerce.com/document/creating-a-bookable-product/)

      Thanks.

    • #126624
      eritechdeveloper
      Participant

      Thank you for your response Sarmistha,

      All that worked like a dream, I would like to remove some more fields, but before I do. Please help me with the following issue that I posted here.

      https://wclovers.com/forums/topic/how-do-i-setup-global-rule-for-bookable-product-availability-based-on-store-ho/

    • #127006
      eritechdeveloper
      Participant

      Hi Sarmistha,

      Can you help me with the document to do the following for code snippets, or help me with the code snippets.

      Default Booking duration to fixed blocks of and remove the dropdown for fixed blocks off
      Default can be cancelled to yes and hide it
      Default can be cancelled up until 24 hours and hide it
      Default Calendar display mode to “display calendar on click” and hide it
      Default max bookings per block to 1 and hide it
      Default all dates are to not available by default and hide it
      Change “rules” in the availability tab to Service Available
      Change minimum block bookable to earliest availability
      Change maximum block bookable to latest availability
      Change require a buffer period of to “Add a break between bookings”
      Remove adjacent buffering
      Remove restrictable selectable days
      Remove restricted days
      Remove first block starts at
      Remove availability rules
      Remove Display cost
      Remove Cost rules
      Rename “Cost” tab to price
      Remove advanced tab as long as enable reviews is defaulted
      Remove tags
      Remove Catalog Visibility
      Remove block cost

      Thanks,
      Robel

    • #127050

      Hello,

      This is not possible using code snippet.
      It requires good amount custom development, and this will be a paid one.
      If you are interested then please contact us here –https://wclovers.com/setup-guidance/ with requirement.

      Thank You

    • #127057
      eritechdeveloper
      Participant

      Thank you for your response, I have sent a request.

    • #127593
      eritechdeveloper
      Participant

      I understand you guys at the moment is there any way we can reduce some of them using snippets and the rest we can look at after when you got time.

Viewing 6 reply threads
  • You must be logged in to reply to this topic.