Git Product home page Git Product logo

bookings-helper's Introduction

bookings-helper

This extension is a WooCommerce Bookings helper which helps you to troubleshoot bookings setups easier by allowing you to quickly export/import product settings.

All exports will be in JSON file format zipped.

Minimum Version Requirements

  • WordPress 5.6
  • WooCommerce 6.0
  • PHP 7.0

Global Availability Rules

Importing global availability rules will overwrite all the rules. This is because a bookable product test case will depend on these rules. Since this is an overwriting feature, you can first export the global availability rules for safe keeping before you import your test rules. This way you can always import back your original rules.

Bookable Product

You can export any specific bookable product and all of its settings including resources and persons.

If resources are defined, importing the bookable product will generate new resources that will be linked to the specific product you imported.

You can also use wp-cli to import/export bookable products and availability rules. See the example below.

# Export all products
wp bookings-helper export-products --all --dir=/absolute/path/to/directory/

# Export specific products
wp bookings-helper export-products --products="1,2" --dir=/absolute/path/to/directory/

# Export all products with global availability rules
wp bookings-helper export-products --all --with-global-rules

# Import all products
wp bookings-helper import-products --file=/absolute/path/to/file

# Export global availability rules
wp bookings-helper export-global-availability-rules --dir=/absolute/path/to/directory/

# Import global availability rules
wp bookings-helper import-global-availability-rules --file=/absolute/path/to/directory/

# Import all products with global availability rules
wp bookings-helper import-product --file=/absolute/path/to/file --with-global-rules

Usage

Just install the plugin and activate. Then go to "Tools->Bookings Helper".

bookings-helper's People

Contributors

dkotter avatar dwainm avatar faisal-alvi avatar jeffpaul avatar jessepearson avatar ravinderk avatar roykho avatar sir-daniel avatar vikrampm1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bookings-helper's Issues

Resource Costs empty when imported

While working on the #24, I have noticed the resources costs (base cost and block cost) are being exported correctly and available in the exported zip/JSON file, but it is not imported, the base cost and block costs remain empty/0.00.

Steps to regenerate.

  1. Create a bookable product.
  2. Tick "Has Resource".
  3. Add 2 resources.
  4. Add any amount to "Base Cost" and "Block Cost".
  5. Export the products from Tools > Bookings Helper.
  6. Import the exported from Tools > Bookings Helper (same page).
  7. Visit the Products page and check the newly imported product.
  8. Check the "Resources" tab.
  9. You will see the amounts entered in the "Base Cost" and "Block Cost" is not imported, It is 0.00.

Update bookings-helper plugin.

Updating recurring events in woocommerce-bookings requires review and most probably update of the bookings-helper plugin to match new implementation.

Add WP CLI command to export & import all booking products

Details

I expect the WP CLI command to export and import all products.

Expectations with the WP CLI feature would be:

  • Run wp booking-helper export-product --all --dir=/absolute/path/to/directory to export all products.
  • Runwp booking-helper import-product --file=/absolute/path/to/file/ to import all products.
  • Run wp booking-helper export-availability-rules --dir=/absolute/path/to/directory to export global availability rules.
  • Run wp booking-helper import-availability-rules --file=/absolute/path/to/directory to import global availability rules.

export / import .xls

Hello, I need to prepare the output of the files in Excel
Because I need to batch import products with details for each subject

Enhancement: Ability to import a single zip for Product & Global Rules together

A helping enhancement is required to the main export feature introduced in https://github.com/woocommerce/woocommerce-bookings/pull/3386.

The ZIP generated by clicking the "Export" button on the product page, contains its settings, applicable resources, persons, and global availability rules. When importing this ZIP, it should import product data and the global availability rules.

Also, add a checkbox (unticked by default) to allow HEs to determine if global rules should "also" be imported along with the product.

Add bulk import feature to user interface

Details

Admin can import one booking product at a time. It will be good if the admin can import products in bulk from the user interface. We add this feature to wp cli command

Acceptance Criteria

  • Admin has the option to import multiple selected booking products.
  • Admin has the option to import all booking products.

Lots of warnings and errors on import

Trying to import this gave me all kinds of nasty errors:
https://bookingsdemo.blog/wp-content/uploads/2019/07/bookings-demos-yoga-class.zip from
https://bookingsdemo.blog/product/yoga-class/

Bookings Helper 1.0.2
WordPress 5.4
WooCommerce Bookings 1.15.15
WooCommerce Min/Max Quantities 2.4.15
WooCommerce Smart Coupons 4.7.1
WooCommerce 4.0.1

Notice: Undefined index: gcal_event_id in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 489

Notice: Undefined index: title in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 490

Notice: Undefined index: range_type in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 491

Notice: Undefined index: from_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 492

Notice: Undefined index: to_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 493

Notice: Undefined index: from_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 494

Notice: Undefined index: to_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 495

Notice: Undefined index: bookable in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 496

Notice: Undefined index: priority in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 497

Notice: Undefined index: ordering in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 498

Notice: Undefined index: date_created in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 499

Notice: Undefined index: date_modified in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 500

Notice: Undefined index: rrule in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 501

Notice: wpdb::prepare was called incorrectly. The query argument of wpdb::prepare() must have a placeholder. Please see Debugging in WordPress for more information. (This message was added in version 3.9.0.) in D:\laragon\www\my-site\wp-includes\functions.php on line 5167

WordPress database error: [Column 'gcal_event_id' cannot be null]
INSERT INTO `wp_wc_bookings_availability` (`gcal_event_id`, `title`, `range_type`, `from_date`, `to_date`, `from_range`, `to_range`, `bookable`, `priority`, `ordering`, `date_created`, `date_modified`, `rrule`) VALUES (NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)

Notice: Undefined index: gcal_event_id in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 489

Notice: Undefined index: title in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 490

Notice: Undefined index: range_type in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 491

Notice: Undefined index: from_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 492

Notice: Undefined index: to_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 493

Notice: Undefined index: from_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 494

Notice: Undefined index: to_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 495

Notice: Undefined index: bookable in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 496

Notice: Undefined index: priority in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 497

Notice: Undefined index: ordering in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 498

Notice: Undefined index: date_created in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 499

Notice: Undefined index: date_modified in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 500

Notice: Undefined index: rrule in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 501

Notice: wpdb::prepare was called incorrectly. The query argument of wpdb::prepare() must have a placeholder. Please see Debugging in WordPress for more information. (This message was added in version 3.9.0.) in D:\laragon\www\my-site\wp-includes\functions.php on line 5167

WordPress database error: [Column 'gcal_event_id' cannot be null]
INSERT INTO `wp_wc_bookings_availability` (`gcal_event_id`, `title`, `range_type`, `from_date`, `to_date`, `from_range`, `to_range`, `bookable`, `priority`, `ordering`, `date_created`, `date_modified`, `rrule`) VALUES (NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)

Notice: Undefined index: gcal_event_id in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 489

Notice: Undefined index: title in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 490

Notice: Undefined index: range_type in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 491

Notice: Undefined index: from_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 492

Notice: Undefined index: to_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 493

Notice: Undefined index: from_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 494

Notice: Undefined index: to_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 495

Notice: Undefined index: bookable in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 496

Notice: Undefined index: priority in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 497

Notice: Undefined index: ordering in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 498

Notice: Undefined index: date_created in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 499

Notice: Undefined index: date_modified in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 500

Notice: Undefined index: rrule in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 501

Notice: wpdb::prepare was called incorrectly. The query argument of wpdb::prepare() must have a placeholder. Please see Debugging in WordPress for more information. (This message was added in version 3.9.0.) in D:\laragon\www\my-site\wp-includes\functions.php on line 5167

WordPress database error: [Column 'gcal_event_id' cannot be null]
INSERT INTO `wp_wc_bookings_availability` (`gcal_event_id`, `title`, `range_type`, `from_date`, `to_date`, `from_range`, `to_range`, `bookable`, `priority`, `ordering`, `date_created`, `date_modified`, `rrule`) VALUES (NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)

Notice: Undefined index: gcal_event_id in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 489

Notice: Undefined index: title in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 490

Notice: Undefined index: range_type in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 491

Notice: Undefined index: from_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 492

Notice: Undefined index: to_date in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 493

Notice: Undefined index: from_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 494

Notice: Undefined index: to_range in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 495

Notice: Undefined index: bookable in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 496

Notice: Undefined index: priority in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 497

Notice: Undefined index: ordering in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 498

Notice: Undefined index: date_created in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 499

Notice: Undefined index: date_modified in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 500

Notice: Undefined index: rrule in D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php on line 501

Notice: wpdb::prepare was called incorrectly. The query argument of wpdb::prepare() must have a placeholder. Please see Debugging in WordPress for more information. (This message was added in version 3.9.0.) in D:\laragon\www\my-site\wp-includes\functions.php on line 5167

WordPress database error: [Column 'gcal_event_id' cannot be null]
INSERT INTO `wp_wc_bookings_availability` (`gcal_event_id`, `title`, `range_type`, `from_date`, `to_date`, `from_range`, `to_range`, `bookable`, `priority`, `ordering`, `date_created`, `date_modified`, `rrule`) VALUES (NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)

Warning: Cannot modify header information - headers already sent by (output started at D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php:494) in D:\laragon\www\my-site\wp-includes\functions.php on line 6221

Warning: Cannot modify header information - headers already sent by (output started at D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php:494) in D:\laragon\www\my-site\wp-admin\includes\misc.php on line 1259

Warning: Cannot modify header information - headers already sent by (output started at D:\laragon\www\my-site\wp-content\plugins\bookings-helper-master\bookings-helper.php:494) in D:\laragon\www\my-site\wp-admin\admin-header.php on line 9

1.0.6 tagged version contains no release zip

Issue
The 1.0.6 tag contains no release zip, and the code download zip of that version causes a fatal error here.

The bookings-helper.zip release version in the 1.0.5 tagged version is in fact version 1.0.3

This plugin is occasionally shared with vendors and the link provided to the merchant in 6082694-zen caused the merchant site to crash.

Expected
A matching bookings-helper.zip version which does not cause fatal errors is included in the tagged release.

Release version 1.0.7

This issue is for tracking the 1.0.7 release. Target release date: December 04 2023

Description

  • Correct the previous release version with a new release zip Ref: #36 (comment)

Release steps

  • Branch: Starting from master, cut a release branch named release/1.0.7
  • Version bump: Bump the version number in bookings-helper.php to 1.0.7. In bookings-helper.php update both the plugin "Version:" property and the plugin WC_BOOKINGS_HELPER_VERSION constant
  • Update @since: Find all new @since x.x.x / @since n.e.x.t lines and update those with the new version number, 1.0.7
  • Update changelog: Ensure the changelog.txt has all merged PRs in it
  • Open PR: Open a new PR against trunk from the release branch, release/1.0.7
  • Merge: Merge the release PR into trunk
  • Prepare ZIP: Prepare the zip by running composer install --no-dev && composer archive --file=bookings-helper --format=zip locally
  • Compare: Download the latest released zip and then run a diff compare against the generated zip, ensuring all expected changes are there (and no unexpected changes)
  • Test ZIP: Take the ZIP generated from the previous step and test this locally, ensuring version numbers look correct, the changelog looks correct and the plugin installs and activates properly
  • Attach ZIP: Attach the ZIP to this issue and ping the Automattic team in the #a8c-10up-woo-support channel to complete the release

Doesn't find global availability rules to export

One global availability rule is set, but clicking "export rules" shows the notification "There are no rules to export."

Error
Full size: http://cld.wthms.co/zsChqA

Rule:

Global availability
Full size: http://cld.wthms.co/YNcFWG

`

WordPress Environment

Home URL: http://wordpress.local
Site URL: http://wordpress.local
WC Version: 3.5.4
Log Directory Writable: ✔
WP Version: 5.0.3
WP Multisite: –
WP Memory Limit: 256 MB
WP Debug Mode: –
WP Cron: ✔
Language: en_US
External object cache: –

Server Environment

Server Info: nginx/1.14.0
PHP Version: 7.2.9
PHP Post Max Size: 1,000 MB
PHP Time Limit: 1200
PHP Max Input Vars: 4000
cURL Version: 7.52.1
OpenSSL/1.0.2l

SUHOSIN Installed: –
MySQL Version: 5.7.23
Max Upload Size: 300 MB
Default Timezone is UTC: ✔
fsockopen/cURL: ✔
SoapClient: ✔
DOMDocument: ✔
GZip: ✔
Multibyte String: ✔
Remote Post: ✔
Remote Get: ✔

Database

WC Database Version: 3.5.4
WC Database Prefix: wp_
MaxMind GeoIP Database: ✔
Total Database Size: 2.89MB
Database Data Size: 1.88MB
Database Index Size: 1.01MB
wp_woocommerce_sessions: Data: 0.02MB + Index: 0.02MB
wp_woocommerce_api_keys: Data: 0.02MB + Index: 0.03MB
wp_woocommerce_attribute_taxonomies: Data: 0.02MB + Index: 0.02MB
wp_woocommerce_downloadable_product_permissions: Data: 0.02MB + Index: 0.05MB
wp_woocommerce_order_items: Data: 0.02MB + Index: 0.02MB
wp_woocommerce_order_itemmeta: Data: 0.02MB + Index: 0.03MB
wp_woocommerce_tax_rates: Data: 0.02MB + Index: 0.06MB
wp_woocommerce_tax_rate_locations: Data: 0.02MB + Index: 0.03MB
wp_woocommerce_shipping_zones: Data: 0.02MB + Index: 0.00MB
wp_woocommerce_shipping_zone_locations: Data: 0.02MB + Index: 0.03MB
wp_woocommerce_shipping_zone_methods: Data: 0.02MB + Index: 0.00MB
wp_woocommerce_payment_tokens: Data: 0.02MB + Index: 0.02MB
wp_woocommerce_payment_tokenmeta: Data: 0.02MB + Index: 0.03MB
wp_woocommerce_log: Data: 0.02MB + Index: 0.02MB
wp_commentmeta: Data: 0.02MB + Index: 0.03MB
wp_comments: Data: 0.02MB + Index: 0.09MB
wp_failed_jobs: Data: 0.02MB + Index: 0.00MB
wp_links: Data: 0.02MB + Index: 0.02MB
wp_mailchimp_carts: Data: 0.02MB + Index: 0.00MB
wp_options: Data: 1.03MB + Index: 0.05MB
wp_postmeta: Data: 0.14MB + Index: 0.11MB
wp_posts: Data: 0.06MB + Index: 0.06MB
wp_queue: Data: 0.02MB + Index: 0.00MB
wp_termmeta: Data: 0.02MB + Index: 0.03MB
wp_terms: Data: 0.02MB + Index: 0.03MB
wp_term_relationships: Data: 0.02MB + Index: 0.02MB
wp_term_taxonomy: Data: 0.02MB + Index: 0.03MB
wp_usermeta: Data: 0.02MB + Index: 0.03MB
wp_users: Data: 0.02MB + Index: 0.05MB
wp_wc_bookings_availability: Data: 0.02MB + Index: 0.02MB
wp_wc_booking_relationships: Data: 0.02MB + Index: 0.03MB
wp_wc_download_log: Data: 0.02MB + Index: 0.03MB
wp_wc_webhooks: Data: 0.02MB + Index: 0.02MB
wp_wpml_mails: Data: 0.05MB + Index: 0.00MB

Post Type Counts

attachment: 20
customize_changeset: 2
nav_menu_item: 5
page: 8
post: 5
product: 17
product_variation: 3
revision: 7
scheduled-action: 5
shop_coupon: 1
shop_order: 6
wc_booking: 1

Security

Secure connection (HTTPS): ❌
Your store is not using HTTPS. Learn more about HTTPS and SSL Certificates.
Hide errors from visitors: ✔

Active Plugins (5)

Bookings Helper: by WooCommerce – 1.0.2 – Not tested with the active version of WooCommerce
WooCommerce Blocks: by Automattic – 1.3.1
WooCommerce Bookings: by Automattic – 1.13.0-rc.2
WooCommerce: by Automattic – 3.5.4
WP Mail Logging: by Christian Zöller – 1.8.5

Settings

API Enabled: –
Force SSL: –
Currency: EUR (€)
Currency Position: left
Thousand Separator: ,
Decimal Separator: .
Number of Decimals: 2
Taxonomies: Product Types: booking (booking)
external (external)
grouped (grouped)
photography (photography)
simple (simple)
subscription (subscription)
variable (variable)
variable subscription (variable-subscription)

Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog)
exclude-from-search (exclude-from-search)
featured (featured)
outofstock (outofstock)
rated-1 (rated-1)
rated-2 (rated-2)
rated-3 (rated-3)
rated-4 (rated-4)
rated-5 (rated-5)

WC Pages

Shop base: #5 - /shop/
Cart: #6 - /cart/
Checkout: #7 - /checkout/
My account: #8 - /my-account/
Terms and conditions: ❌ Page not set

Theme

Name: Storefront
Version: 2.4.2
Author URL: https://woocommerce.com/
Child Theme: ❌ – If you are modifying WooCommerce on a parent theme that you did not build personally we recommend using a child theme. See: How to create a child theme
WooCommerce Support: ✔

Templates

Overrides: –
`

Bump WP, Woo, & PHP Minimums

Bump WP, Woo & PHP Minimums to the following

  • WordPress to 5.6
  • WooCommerce to 6.0
  • PHP to 7.0
  • Scan for any conditional checks that may be in the code that can be removed with these minimum bumps

Add PHP Compat Testing GitHub Action

Description:

Add PHP Compatibility testing through the PHPCompatibilityWP ruleset. This testing should run through Github Actions.

Note: full PHP 8.0 testing is not yet available in the PHPCompatibility ruleset (which the PHPCompatibilityWP uses). The 10.0 release of that is supposed to be coming in the next month or so and is supposed to have close to full 8.0 support.

Booking Product imported by Booking Helper, doesn't have formatting in content

If a booking product has content with formatting, imported version of booking product doesn't have those formatting.

Original Booking Content -

image

Imported Booking Content-

image

Steps -

  1. Create a booking product with some content in the editor
  2. Make content bold, heading, an ordered list, an unordered list, etc
  3. Export the product with the help of Booking Helper
  4. Import that product again and check the content of the booking.

Not sure if this scenario is considered or not at the time of designing this plugin. Feel free to close this issue if this is intentional.

Code Cleanup/Improvements

Clean up the code in the plugin.

  • Only a single file is used, separate it into different files if applicable
  • Standardized the code, use escaping functions.
  • Make strings translatable.
  • Run PHPCS and fix warnings/errors.
  • Remove unnecessary code.

WP CLI support

Common flow using this helper is:

  • A goes to the Helper page
  • A exports by specifying product ID
  • A goes to the download folder in their OS
  • A makes zip archive of exported JSON file
  • A uploads that in GH issue
  • B downloads zip file from GH issue
  • B unzips the zip
  • B goes to the Helper page
  • B imports JSON file

Expectation with WP CLI feature would be:

  • A runs wp booking-helper export-product 1234 --file=~/Desktop/1234.json.zip
  • A uploads ~/Desktop/1234.json.zip in GH issue
  • B copies link in GH issue and runs wp booking-helper import-product <copied-url-from-above>

Fatal error on resources edit page and calendar loading endlessly when product imported through bookings helper

I was working on a ticket with a different issue. (5582280-zen)

I imported one of the products from user's site and checked on my test site:

  1. The calendar doesn't load up (Infinite spinning)
  2. Fatal error is thrown on Resource edit page.

ZIP of the product: https://d.pr/f/KDLyCm

2022-09-27T04:37:10+00:00 CRITICAL Uncaught TypeError: Cannot access offset of type string on string in /var/www/site/public_html/sites/wp-3559132/wp-content/plugins/woocommerce-bookings/includes/admin/views/html-booking-availability-fields.php:43

(PHP 8.xx)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.