From e36f44ebee323e136091aaebc90e5fd8943a1e80 Mon Sep 17 00:00:00 2001 From: WooCommerce Date: Fri, 11 Aug 2023 10:11:32 +0000 Subject: [PATCH] Updates to 5.3.1 --- changelog.txt | 8 + languages/woocommerce-subscriptions.pot | 268 +++++++++--------- vendor/autoload.php | 2 +- vendor/composer/ClassLoader.php | 96 ++++--- vendor/composer/autoload_real.php | 8 +- vendor/composer/autoload_static.php | 8 +- vendor/composer/installed.json | 14 +- vendor/composer/installed.php | 18 +- .../assets/css/admin-empty-state.css | 26 ++ .../images/subscriptions-empty-state.svg | 1 + .../assets/js/admin/admin.js | 5 + .../subscriptions-core/changelog.txt | 6 + ...s-wcs-admin-empty-list-content-manager.php | 97 +++++++ .../class-wc-subscriptions-core-plugin.php | 29 +- .../class-wc-subscriptions-data-copier.php | 1 + ...wc-subscriptions-extend-store-endpoint.php | 4 + .../includes/wcs-order-functions.php | 1 + .../admin/html-admin-empty-list-table.php | 20 ++ .../subscriptions-core/wcs-functions.php | 8 +- .../woocommerce-subscriptions-core.php | 2 +- woocommerce-subscriptions.php | 10 +- 21 files changed, 395 insertions(+), 237 deletions(-) create mode 100644 vendor/woocommerce/subscriptions-core/assets/css/admin-empty-state.css create mode 100644 vendor/woocommerce/subscriptions-core/assets/images/subscriptions-empty-state.svg create mode 100644 vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-empty-list-content-manager.php create mode 100644 vendor/woocommerce/subscriptions-core/templates/admin/html-admin-empty-list-table.php diff --git a/changelog.txt b/changelog.txt index b4b6990..1f548dd 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,5 +1,13 @@ *** WooCommerce Subscriptions Changelog *** +2023-08-11 - version 5.4.0 +* Add: Introduce an updated empty state screen for the WooCommerce > Subscriptions list table. +* Fix: Ensure subscription checkout and cart block integrations are loaded on store environments where WooPayments is not enabled. +* Fix: Ensure the shipping phone number field is copied to subscriptions and their orders when copying address meta. +* Update: When HPOS is disabled, fetch subscriptions by customer_id using the user's subscription cache to improve performance. +* Dev: Deprecated the 'woocommerce_subscriptions_not_found_label' filter. +* Dev: Updated subscriptions-core to 6.2.0 + 2023-07-26 - version 5.3.1 * Fix: Resolved an issue that prevented the "Used for variations" checkbox to not be enabled on the edit product page load causing variations to be deleted erroneously. * Dev: Fixed wcs_get_subscription_orders() returning an empty list when querying parent orders when HPOS is enabled with data syncing off. diff --git a/languages/woocommerce-subscriptions.pot b/languages/woocommerce-subscriptions.pot index 04006e1..49fcf9f 100644 --- a/languages/woocommerce-subscriptions.pot +++ b/languages/woocommerce-subscriptions.pot @@ -2,16 +2,16 @@ # This file is distributed under the same license as the WooCommerce Subscriptions plugin. msgid "" msgstr "" -"Project-Id-Version: WooCommerce Subscriptions 5.3.1\n" +"Project-Id-Version: WooCommerce Subscriptions 5.4.0\n" "Report-Msgid-Bugs-To: https://woocommerce.com/contact-us\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"POT-Creation-Date: 2023-07-26T05:12:54+00:00\n" +"POT-Creation-Date: 2023-08-11T00:44:39+00:00\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" -"X-Generator: WP-CLI 2.8.1\n" +"X-Generator: WP-CLI 2.8.0\n" "X-Domain: woocommerce-subscriptions\n" #. Plugin Name of the plugin @@ -54,8 +54,8 @@ msgstr "" #: vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-system-status.php:59 #: vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-wc-admin-manager.php:38 #: vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-wc-admin-manager.php:80 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:350 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:363 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:336 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:349 #: vendor/woocommerce/subscriptions-core/includes/class-wcs-query.php:108 #: vendor/woocommerce/subscriptions-core/includes/class-wcs-query.php:133 #: vendor/woocommerce/subscriptions-core/includes/class-wcs-query.php:287 @@ -721,16 +721,16 @@ msgstr "" #: includes/api/class-wc-rest-subscriptions-controller.php:384 #: includes/api/legacy/class-wc-rest-subscriptions-controller.php:350 #: includes/api/v1/class-wc-rest-subscriptions-v1-controller.php:506 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:175 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:449 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:179 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:453 msgid "The number of billing periods between subscription renewals." msgstr "" #: includes/api/class-wc-rest-subscriptions-controller.php:389 #: includes/api/legacy/class-wc-rest-subscriptions-controller.php:355 #: includes/api/v1/class-wc-rest-subscriptions-v1-controller.php:511 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:168 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:442 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:172 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:446 msgid "Billing period for the subscription." msgstr "" @@ -867,7 +867,7 @@ msgstr "" #: includes/api/legacy/class-wc-rest-subscriptions-controller.php:383 #: includes/api/v1/class-wc-rest-subscriptions-v1-controller.php:539 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:436 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:440 msgid "The subscription's next payment date." msgstr "" @@ -1013,7 +1013,7 @@ msgid "Add a Subscription Product" msgstr "" #: includes/class-wc-subscriptions-plugin.php:223 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:526 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:512 #: vendor/woocommerce/subscriptions-core/includes/upgrades/templates/wcs-about-2-0.php:35 #: vendor/woocommerce/subscriptions-core/includes/upgrades/templates/wcs-about.php:34 msgid "Settings" @@ -1871,46 +1871,6 @@ msgstr "" msgid "Want to renew early via the checkout? Click %shere.%s" msgstr "" -#: tests/unit/scheduler/scheduler.php:65 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:291 -msgctxt "table heading" -msgid "Start Date" -msgstr "" - -#: tests/unit/scheduler/scheduler.php:66 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:292 -msgctxt "table heading" -msgid "Trial End" -msgstr "" - -#: tests/unit/scheduler/scheduler.php:67 -#: vendor/woocommerce/subscriptions-core/templates/myaccount/my-subscriptions.php:40 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:293 -msgctxt "table heading" -msgid "Next Payment" -msgstr "" - -#: tests/unit/scheduler/scheduler.php:68 -#: vendor/woocommerce/subscriptions-core/templates/emails/cancelled-subscription.php:23 -#: vendor/woocommerce/subscriptions-core/templates/emails/expired-subscription.php:23 -#: vendor/woocommerce/subscriptions-core/templates/emails/on-hold-subscription.php:23 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:294 -msgctxt "table heading" -msgid "Last Order Date" -msgstr "" - -#: tests/unit/scheduler/scheduler.php:69 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:295 -msgctxt "table heading" -msgid "Cancelled Date" -msgstr "" - -#: tests/unit/scheduler/scheduler.php:70 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:296 -msgctxt "table heading" -msgid "End Date" -msgstr "" - #. translators: 1: relation type, 2: list of valid relation types. #: vendor/woocommerce/subscriptions-core/includes/abstracts/abstract-wcs-related-order-store.php:148 msgid "Invalid relation type: %1$s. Order relationship type must be one of: %2$s." @@ -2124,7 +2084,7 @@ msgid "Manage Subscriptions" msgstr "" #: vendor/woocommerce/subscriptions-core/includes/admin/class-wc-subscriptions-admin.php:1008 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:359 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:345 msgid "Search Subscriptions" msgstr "" @@ -2243,6 +2203,10 @@ msgstr "" msgid "Allow subscription customers to create an account during checkout" msgstr "" +#: vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-empty-list-content-manager.php:29 +msgid "No subscriptions found." +msgstr "" + #: vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-meta-boxes.php:83 msgctxt "meta box title" msgid "Subscription Data" @@ -2410,7 +2374,7 @@ msgid "Status" msgstr "" #: vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-post-types.php:464 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:351 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:337 #: vendor/woocommerce/subscriptions-core/templates/emails/cancelled-subscription.php:21 #: vendor/woocommerce/subscriptions-core/templates/emails/expired-subscription.php:21 #: vendor/woocommerce/subscriptions-core/templates/emails/on-hold-subscription.php:21 @@ -2841,7 +2805,7 @@ msgid "Customer add payment method page →" msgstr "" #: vendor/woocommerce/subscriptions-core/includes/admin/meta-boxes/class-wcs-meta-box-subscription-data.php:253 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:287 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:291 #: vendor/woocommerce/subscriptions-core/build/index.js:6 msgid "Shipping" msgstr "" @@ -3008,7 +2972,7 @@ msgid "The \"all\" value for $order_type parameter is deprecated. It was a misno msgstr "" #: vendor/woocommerce/subscriptions-core/includes/class-wc-subscription.php:2127 -#: vendor/woocommerce/subscriptions-core/wcs-functions.php:829 +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:835 msgid "Payment method meta must be an array." msgstr "" @@ -3311,71 +3275,53 @@ msgstr "" msgid "Purchasing a subscription product requires an account. Please go to the %1$sMy Account%2$s page to login or contact us if you need assistance." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:332 -msgid "No Subscriptions found" -msgstr "" - -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:334 -msgid "Subscriptions will appear here for you to view and manage once purchased by a customer." -msgstr "" - -#. translators: placeholders are opening and closing link tags -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:336 -msgid "%1$sLearn more about managing subscriptions »%2$s" -msgstr "" - -#. translators: placeholders are opening and closing link tags #: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:338 -msgid "%1$sAdd a subscription product »%2$s" -msgstr "" - -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:352 msgctxt "custom post type setting" msgid "Add Subscription" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:353 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:339 msgctxt "custom post type setting" msgid "Add New Subscription" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:354 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:340 msgctxt "custom post type setting" msgid "Edit" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:355 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:341 msgctxt "custom post type setting" msgid "Edit Subscription" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:356 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:342 msgctxt "custom post type setting" msgid "New Subscription" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:357 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:358 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:343 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:344 msgctxt "custom post type setting" msgid "View Subscription" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:361 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:347 msgctxt "custom post type setting" msgid "No Subscriptions found in trash" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:362 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:348 msgctxt "custom post type setting" msgid "Parent Subscriptions" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:365 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:351 msgid "This is where subscriptions are stored." msgstr "" #. translators: placeholder is a post count. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:423 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:409 msgctxt "post status label including post count" msgid "Active (%s)" msgid_plural "Active (%s)" @@ -3383,7 +3329,7 @@ msgstr[0] "" msgstr[1] "" #. translators: placeholder is a post count. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:425 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:411 msgctxt "post status label including post count" msgid "Switched (%s)" msgid_plural "Switched (%s)" @@ -3391,7 +3337,7 @@ msgstr[0] "" msgstr[1] "" #. translators: placeholder is a post count. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:427 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:413 msgctxt "post status label including post count" msgid "Expired (%s)" msgid_plural "Expired (%s)" @@ -3399,29 +3345,29 @@ msgstr[0] "" msgstr[1] "" #. translators: placeholder is a post count. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:429 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:415 msgctxt "post status label including post count" msgid "Pending Cancellation (%s)" msgid_plural "Pending Cancellation (%s)" msgstr[0] "" msgstr[1] "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:478 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:464 msgid "Variable Subscription" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:527 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:513 #: vendor/woocommerce/subscriptions-core/includes/upgrades/templates/wcs-about-2-0.php:36 msgctxt "short for documents" msgid "Docs" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:528 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:514 msgid "Support" msgstr "" #. translators: placeholders are opening and closing tags. Leads to docs on version 2 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:551 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php:537 msgid "Warning! Version 2.0 is a major update to the WooCommerce Subscriptions extension. Before updating, please create a backup, update all WooCommerce extensions and test all plugins, custom code and payment gateways with version 2.0 on a staging site. %1$sLearn more about the changes in version 2.0 »%2$s" msgstr "" @@ -3500,180 +3446,180 @@ msgstr "" msgid "Discount" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:181 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:185 msgid "Subscription Product length." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:187 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:191 msgid "Subscription Product trial period." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:194 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:198 msgid "Subscription Product trial interval." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:200 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:204 msgid "Subscription Product signup fees." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:206 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:210 msgid "Subscription Product signup fees taxes." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:212 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:216 msgid "Indicates whether this product is being used to resubscribe the customer to an existing, expired subscription." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:221 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:225 msgid "Indicates whether this product a subscription update, downgrade, cross grade or none of the above." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:230 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:234 msgid "Synchronization data for the subscription." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:234 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:238 msgid "Synchronization day if subscription is annual." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:238 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:242 msgid "Synchronization month if subscription is annual." msgstr "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:293 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:297 msgid "Shipment every %d year" msgid_plural "Shipment every %d years" msgstr[0] "" msgstr[1] "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:293 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:297 msgid "Yearly Shipment" msgstr "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:297 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:301 msgid "Shipment every %d month" msgid_plural "Shipment every %d months" msgstr[0] "" msgstr[1] "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:297 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:301 msgid "Monthly Shipment" msgstr "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:301 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:305 msgid "Shipment every %d week" msgid_plural "Shipment every %d weeks" msgstr[0] "" msgstr[1] "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:301 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:305 msgid "Weekly Shipment" msgstr "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:305 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:309 msgid "Shipment every %d day" msgid_plural "Shipment every %d days" msgstr[0] "" msgstr[1] "" #. translators: %d subscription interval. -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:305 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:309 msgid "Daily Shipment" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:430 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:434 msgid "Subscription key" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:455 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:459 msgid "Subscription length." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:461 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:465 msgid "Cart total amounts provided using the smallest unit of the currency." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:467 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:471 msgid "Total price of items in the cart." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:473 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:477 msgid "Total tax on items in the cart." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:479 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:483 msgid "Total price of any applied fees." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:485 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:489 msgid "Total tax on fees." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:491 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:495 msgid "Total discount from applied coupons." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:497 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:501 msgid "Total tax removed due to discount from applied coupons." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:503 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:507 msgid "Total price of shipping. If shipping has not been calculated, a null response will be sent." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:509 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:513 msgid "Total tax on shipping. If shipping has not been calculated, a null response will be sent." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:515 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:519 msgid "Total price the customer will pay." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:521 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:525 msgid "Total tax applied to items and shipping." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:527 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:531 msgid "Lines of taxes applied to items and shipping." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:535 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:539 msgid "The name of the tax." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:541 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:545 msgid "The amount of tax charged." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:550 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:554 msgid "Currency code (in ISO format) for returned prices." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:556 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:560 msgid "Currency symbol for the currency which can be used to format returned prices." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:562 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:566 msgid "Currency minor unit (number of digits after the decimal separator) for returned prices." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:568 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:572 msgid "Decimal separator for the currency which can be used to format returned prices." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:574 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:578 msgid "Thousand separator for the currency which can be used to format returned prices." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:580 -#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:586 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:584 +#: vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php:590 msgid "Price prefix for the currency which can be used to format returned prices." msgstr "" @@ -5989,46 +5935,46 @@ msgstr "" msgid "Invalid sort order type: %1$s. The $sort_order argument must be %2$s or %3$s." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:142 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:143 msgctxt "In wcs_copy_order_meta error message. Refers to origin and target order objects." msgid "Invalid data. Orders expected aren't orders." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:146 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:147 msgctxt "Refers to the type of the copy being performed: \"copy_order\", \"subscription\", \"renewal_order\", \"resubscribe_order\"" msgid "Invalid data. Type of copy is not a string." msgstr "" #. translators: placeholders are strftime() strings. -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:249 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:250 msgctxt "Used in subscription post title. \"Subscription renewal order - \"" msgid "%b %d, %Y @ %I:%M %p" msgstr "" #. translators: placeholder is a date. -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:254 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:255 msgid "Subscription Renewal Order – %s" msgstr "" #. translators: placeholder is a date. -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:258 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:259 msgid "Resubscribe Order – %s" msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:277 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:278 msgid "$type passed to the function was not a string." msgstr "" #. translators: placeholder is an order type. -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:282 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:283 msgid "\"%s\" is not a valid new order type." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:533 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:534 msgid "Invalid data. No valid subscription / order was passed in." msgstr "" -#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:537 +#: vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php:538 msgid "Invalid data. No valid item id was passed in." msgstr "" @@ -6204,6 +6150,14 @@ msgstr "" msgid "Shipping Tax:" msgstr "" +#: vendor/woocommerce/subscriptions-core/templates/admin/html-admin-empty-list-table.php:14 +msgid "This is where you'll see and manage all subscriptions in your store. Create a subscription product to turn one-time purchases into a steady income." +msgstr "" + +#: vendor/woocommerce/subscriptions-core/templates/admin/html-admin-empty-list-table.php:16 +msgid "Create subscription product" +msgstr "" + #: vendor/woocommerce/subscriptions-core/templates/admin/html-failed-scheduled-action-notice.php:21 msgid "An error has occurred while processing a recent subscription related event. For steps on how to fix the affected subscription and to learn more about the possible causes of this error, please read our guide %1$shere%2$s." msgid_plural "An error has occurred while processing recent subscription related events. For steps on how to fix the affected subscriptions and to learn more about the possible causes of this error, please read our guide %1$shere%2$s." @@ -6368,6 +6322,14 @@ msgctxt "table headings in notification email" msgid "Price" msgstr "" +#: vendor/woocommerce/subscriptions-core/templates/emails/cancelled-subscription.php:23 +#: vendor/woocommerce/subscriptions-core/templates/emails/expired-subscription.php:23 +#: vendor/woocommerce/subscriptions-core/templates/emails/on-hold-subscription.php:23 +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:294 +msgctxt "table heading" +msgid "Last Order Date" +msgstr "" + #: vendor/woocommerce/subscriptions-core/templates/emails/cancelled-subscription.php:24 msgctxt "table headings in notification email" msgid "End of Prepaid Term" @@ -6650,6 +6612,12 @@ msgstr "" msgid "ID" msgstr "" +#: vendor/woocommerce/subscriptions-core/templates/myaccount/my-subscriptions.php:40 +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:293 +msgctxt "table heading" +msgid "Next Payment" +msgstr "" + #: vendor/woocommerce/subscriptions-core/templates/myaccount/my-subscriptions.php:46 #: vendor/woocommerce/subscriptions-core/templates/myaccount/related-orders.php:53 #: vendor/woocommerce/subscriptions-core/templates/myaccount/related-subscriptions.php:42 @@ -6829,6 +6797,26 @@ msgstr "" msgid "Can not get address type display name. Address type is not a string." msgstr "" +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:291 +msgctxt "table heading" +msgid "Start Date" +msgstr "" + +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:292 +msgctxt "table heading" +msgid "Trial End" +msgstr "" + +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:295 +msgctxt "table heading" +msgid "Cancelled Date" +msgstr "" + +#: vendor/woocommerce/subscriptions-core/wcs-functions.php:296 +msgctxt "table heading" +msgid "End Date" +msgstr "" + #: vendor/woocommerce/subscriptions-core/wcs-functions.php:331 msgid "Date type is not a string." msgstr "" diff --git a/vendor/autoload.php b/vendor/autoload.php index 4e39532..e513dce 100644 --- a/vendor/autoload.php +++ b/vendor/autoload.php @@ -22,4 +22,4 @@ require_once __DIR__ . '/composer/autoload_real.php'; -return ComposerAutoloaderInit8568f0690e3926c86f2dbdbb3a1ffeaa::getLoader(); +return ComposerAutoloaderInit1343a378b98b98b93d2e309b8e304370::getLoader(); diff --git a/vendor/composer/ClassLoader.php b/vendor/composer/ClassLoader.php index 7824d8f..a72151c 100644 --- a/vendor/composer/ClassLoader.php +++ b/vendor/composer/ClassLoader.php @@ -45,34 +45,35 @@ class ClassLoader /** @var \Closure(string):void */ private static $includeFile; - /** @var string|null */ + /** @var ?string */ private $vendorDir; // PSR-4 /** - * @var array> + * @var array[] + * @psalm-var array> */ private $prefixLengthsPsr4 = array(); /** - * @var array> + * @var array[] + * @psalm-var array> */ private $prefixDirsPsr4 = array(); /** - * @var list + * @var array[] + * @psalm-var array */ private $fallbackDirsPsr4 = array(); // PSR-0 /** - * List of PSR-0 prefixes - * - * Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2'))) - * - * @var array>> + * @var array[] + * @psalm-var array> */ private $prefixesPsr0 = array(); /** - * @var list + * @var array[] + * @psalm-var array */ private $fallbackDirsPsr0 = array(); @@ -80,7 +81,8 @@ class ClassLoader private $useIncludePath = false; /** - * @var array + * @var string[] + * @psalm-var array */ private $classMap = array(); @@ -88,20 +90,21 @@ class ClassLoader private $classMapAuthoritative = false; /** - * @var array + * @var bool[] + * @psalm-var array */ private $missingClasses = array(); - /** @var string|null */ + /** @var ?string */ private $apcuPrefix; /** - * @var array + * @var self[] */ private static $registeredLoaders = array(); /** - * @param string|null $vendorDir + * @param ?string $vendorDir */ public function __construct($vendorDir = null) { @@ -110,7 +113,7 @@ public function __construct($vendorDir = null) } /** - * @return array> + * @return string[] */ public function getPrefixes() { @@ -122,7 +125,8 @@ public function getPrefixes() } /** - * @return array> + * @return array[] + * @psalm-return array> */ public function getPrefixesPsr4() { @@ -130,7 +134,8 @@ public function getPrefixesPsr4() } /** - * @return list + * @return array[] + * @psalm-return array */ public function getFallbackDirs() { @@ -138,7 +143,8 @@ public function getFallbackDirs() } /** - * @return list + * @return array[] + * @psalm-return array */ public function getFallbackDirsPsr4() { @@ -146,7 +152,8 @@ public function getFallbackDirsPsr4() } /** - * @return array Array of classname => path + * @return string[] Array of classname => path + * @psalm-return array */ public function getClassMap() { @@ -154,7 +161,8 @@ public function getClassMap() } /** - * @param array $classMap Class to filename map + * @param string[] $classMap Class to filename map + * @psalm-param array $classMap * * @return void */ @@ -171,25 +179,24 @@ public function addClassMap(array $classMap) * Registers a set of PSR-0 directories for a given prefix, either * appending or prepending to the ones previously set for this prefix. * - * @param string $prefix The prefix - * @param list|string $paths The PSR-0 root directories - * @param bool $prepend Whether to prepend the directories + * @param string $prefix The prefix + * @param string[]|string $paths The PSR-0 root directories + * @param bool $prepend Whether to prepend the directories * * @return void */ public function add($prefix, $paths, $prepend = false) { - $paths = (array) $paths; if (!$prefix) { if ($prepend) { $this->fallbackDirsPsr0 = array_merge( - $paths, + (array) $paths, $this->fallbackDirsPsr0 ); } else { $this->fallbackDirsPsr0 = array_merge( $this->fallbackDirsPsr0, - $paths + (array) $paths ); } @@ -198,19 +205,19 @@ public function add($prefix, $paths, $prepend = false) $first = $prefix[0]; if (!isset($this->prefixesPsr0[$first][$prefix])) { - $this->prefixesPsr0[$first][$prefix] = $paths; + $this->prefixesPsr0[$first][$prefix] = (array) $paths; return; } if ($prepend) { $this->prefixesPsr0[$first][$prefix] = array_merge( - $paths, + (array) $paths, $this->prefixesPsr0[$first][$prefix] ); } else { $this->prefixesPsr0[$first][$prefix] = array_merge( $this->prefixesPsr0[$first][$prefix], - $paths + (array) $paths ); } } @@ -219,9 +226,9 @@ public function add($prefix, $paths, $prepend = false) * Registers a set of PSR-4 directories for a given namespace, either * appending or prepending to the ones previously set for this namespace. * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param list|string $paths The PSR-4 base directories - * @param bool $prepend Whether to prepend the directories + * @param string $prefix The prefix/namespace, with trailing '\\' + * @param string[]|string $paths The PSR-4 base directories + * @param bool $prepend Whether to prepend the directories * * @throws \InvalidArgumentException * @@ -229,18 +236,17 @@ public function add($prefix, $paths, $prepend = false) */ public function addPsr4($prefix, $paths, $prepend = false) { - $paths = (array) $paths; if (!$prefix) { // Register directories for the root namespace. if ($prepend) { $this->fallbackDirsPsr4 = array_merge( - $paths, + (array) $paths, $this->fallbackDirsPsr4 ); } else { $this->fallbackDirsPsr4 = array_merge( $this->fallbackDirsPsr4, - $paths + (array) $paths ); } } elseif (!isset($this->prefixDirsPsr4[$prefix])) { @@ -250,18 +256,18 @@ public function addPsr4($prefix, $paths, $prepend = false) throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); } $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = $paths; + $this->prefixDirsPsr4[$prefix] = (array) $paths; } elseif ($prepend) { // Prepend directories for an already registered namespace. $this->prefixDirsPsr4[$prefix] = array_merge( - $paths, + (array) $paths, $this->prefixDirsPsr4[$prefix] ); } else { // Append directories for an already registered namespace. $this->prefixDirsPsr4[$prefix] = array_merge( $this->prefixDirsPsr4[$prefix], - $paths + (array) $paths ); } } @@ -270,8 +276,8 @@ public function addPsr4($prefix, $paths, $prepend = false) * Registers a set of PSR-0 directories for a given prefix, * replacing any others previously set for this prefix. * - * @param string $prefix The prefix - * @param list|string $paths The PSR-0 base directories + * @param string $prefix The prefix + * @param string[]|string $paths The PSR-0 base directories * * @return void */ @@ -288,8 +294,8 @@ public function set($prefix, $paths) * Registers a set of PSR-4 directories for a given namespace, * replacing any others previously set for this namespace. * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param list|string $paths The PSR-4 base directories + * @param string $prefix The prefix/namespace, with trailing '\\' + * @param string[]|string $paths The PSR-4 base directories * * @throws \InvalidArgumentException * @@ -475,9 +481,9 @@ public function findFile($class) } /** - * Returns the currently registered loaders keyed by their corresponding vendor directories. + * Returns the currently registered loaders indexed by their corresponding vendor directories. * - * @return array + * @return self[] */ public static function getRegisteredLoaders() { diff --git a/vendor/composer/autoload_real.php b/vendor/composer/autoload_real.php index 43f63c4..b484d1d 100644 --- a/vendor/composer/autoload_real.php +++ b/vendor/composer/autoload_real.php @@ -2,7 +2,7 @@ // autoload_real.php @generated by Composer -class ComposerAutoloaderInit8568f0690e3926c86f2dbdbb3a1ffeaa +class ComposerAutoloaderInit1343a378b98b98b93d2e309b8e304370 { private static $loader; @@ -24,12 +24,12 @@ public static function getLoader() require __DIR__ . '/platform_check.php'; - spl_autoload_register(array('ComposerAutoloaderInit8568f0690e3926c86f2dbdbb3a1ffeaa', 'loadClassLoader'), true, true); + spl_autoload_register(array('ComposerAutoloaderInit1343a378b98b98b93d2e309b8e304370', 'loadClassLoader'), true, true); self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); - spl_autoload_unregister(array('ComposerAutoloaderInit8568f0690e3926c86f2dbdbb3a1ffeaa', 'loadClassLoader')); + spl_autoload_unregister(array('ComposerAutoloaderInit1343a378b98b98b93d2e309b8e304370', 'loadClassLoader')); require __DIR__ . '/autoload_static.php'; - call_user_func(\Composer\Autoload\ComposerStaticInit8568f0690e3926c86f2dbdbb3a1ffeaa::getInitializer($loader)); + call_user_func(\Composer\Autoload\ComposerStaticInit1343a378b98b98b93d2e309b8e304370::getInitializer($loader)); $loader->register(true); diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index abecd9d..cded1a0 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -4,7 +4,7 @@ namespace Composer\Autoload; -class ComposerStaticInit8568f0690e3926c86f2dbdbb3a1ffeaa +class ComposerStaticInit1343a378b98b98b93d2e309b8e304370 { public static $prefixLengthsPsr4 = array ( 'C' => @@ -129,9 +129,9 @@ class ComposerStaticInit8568f0690e3926c86f2dbdbb3a1ffeaa public static function getInitializer(ClassLoader $loader) { return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInit8568f0690e3926c86f2dbdbb3a1ffeaa::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInit8568f0690e3926c86f2dbdbb3a1ffeaa::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInit8568f0690e3926c86f2dbdbb3a1ffeaa::$classMap; + $loader->prefixLengthsPsr4 = ComposerStaticInit1343a378b98b98b93d2e309b8e304370::$prefixLengthsPsr4; + $loader->prefixDirsPsr4 = ComposerStaticInit1343a378b98b98b93d2e309b8e304370::$prefixDirsPsr4; + $loader->classMap = ComposerStaticInit1343a378b98b98b93d2e309b8e304370::$classMap; }, null, ClassLoader::class); } diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index b900c8f..f689bd4 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -156,17 +156,17 @@ }, { "name": "woocommerce/subscriptions-core", - "version": "6.1.0", - "version_normalized": "6.1.0.0", + "version": "6.2.0", + "version_normalized": "6.2.0.0", "source": { "type": "git", "url": "https://github.com/Automattic/woocommerce-subscriptions-core.git", - "reference": "507720f600363a6c1e7da1b4b82660c7ab6a0c0e" + "reference": "47cfe92d60239d1b8b12a5f640a3772b0e4e1272" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Automattic/woocommerce-subscriptions-core/zipball/507720f600363a6c1e7da1b4b82660c7ab6a0c0e", - "reference": "507720f600363a6c1e7da1b4b82660c7ab6a0c0e", + "url": "https://api.github.com/repos/Automattic/woocommerce-subscriptions-core/zipball/47cfe92d60239d1b8b12a5f640a3772b0e4e1272", + "reference": "47cfe92d60239d1b8b12a5f640a3772b0e4e1272", "shasum": "" }, "require": { @@ -179,7 +179,7 @@ "woocommerce/woocommerce-sniffs": "0.1.0", "yoast/phpunit-polyfills": "1.0.3" }, - "time": "2023-07-26T03:44:54+00:00", + "time": "2023-08-10T23:43:48+00:00", "type": "wordpress-plugin", "extra": { "phpcodesniffer-search-depth": 2 @@ -209,7 +209,7 @@ "description": "Sell products and services with recurring payments in your WooCommerce Store.", "homepage": "https://github.com/Automattic/woocommerce-subscriptions-core", "support": { - "source": "https://github.com/Automattic/woocommerce-subscriptions-core/tree/6.1.0", + "source": "https://github.com/Automattic/woocommerce-subscriptions-core/tree/6.2.0", "issues": "https://github.com/Automattic/woocommerce-subscriptions-core/issues" }, "install-path": "../woocommerce/subscriptions-core" diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 08537f6..406f731 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -1,9 +1,9 @@ array( 'name' => 'woocommerce/woocommerce-subscriptions', - 'pretty_version' => 'dev-release/5.3.1', - 'version' => 'dev-release/5.3.1', - 'reference' => 'de1d1429946caab29ede2bf2d5bc00b16180c916', + 'pretty_version' => 'dev-release/5.4.0', + 'version' => 'dev-release/5.4.0', + 'reference' => '5d0a9898cc3ee9e412b2589bac2588b57a4f681c', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), @@ -32,18 +32,18 @@ ), ), 'woocommerce/subscriptions-core' => array( - 'pretty_version' => '6.1.0', - 'version' => '6.1.0.0', - 'reference' => '507720f600363a6c1e7da1b4b82660c7ab6a0c0e', + 'pretty_version' => '6.2.0', + 'version' => '6.2.0.0', + 'reference' => '47cfe92d60239d1b8b12a5f640a3772b0e4e1272', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../woocommerce/subscriptions-core', 'aliases' => array(), 'dev_requirement' => false, ), 'woocommerce/woocommerce-subscriptions' => array( - 'pretty_version' => 'dev-release/5.3.1', - 'version' => 'dev-release/5.3.1', - 'reference' => 'de1d1429946caab29ede2bf2d5bc00b16180c916', + 'pretty_version' => 'dev-release/5.4.0', + 'version' => 'dev-release/5.4.0', + 'reference' => '5d0a9898cc3ee9e412b2589bac2588b57a4f681c', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), diff --git a/vendor/woocommerce/subscriptions-core/assets/css/admin-empty-state.css b/vendor/woocommerce/subscriptions-core/assets/css/admin-empty-state.css new file mode 100644 index 0000000..7803eba --- /dev/null +++ b/vendor/woocommerce/subscriptions-core/assets/css/admin-empty-state.css @@ -0,0 +1,26 @@ +.woo_subscriptions_empty_state__container { + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + padding: 48px 0; + position: static; + height: 344px; + left: calc(50% - 1240px / 2); + top: 271px; + flex: none; + order: 1; + flex-grow: 0; + margin: 0; + text-align: center; +} +.woo_subscriptions_empty_state__container .woo_subscriptions_empty_state__description { + max-width: 535px; + margin: 15px 0; +} +.woo_subscriptions_empty_state__button_container { + margin: 8px 0; +} +.woo_subscriptions_empty_state__container .woo_subscriptions_empty_state__button_container * + * { + margin-left: 10px; +} diff --git a/vendor/woocommerce/subscriptions-core/assets/images/subscriptions-empty-state.svg b/vendor/woocommerce/subscriptions-core/assets/images/subscriptions-empty-state.svg new file mode 100644 index 0000000..cbd0cc3 --- /dev/null +++ b/vendor/woocommerce/subscriptions-core/assets/images/subscriptions-empty-state.svg @@ -0,0 +1 @@ + diff --git a/vendor/woocommerce/subscriptions-core/assets/js/admin/admin.js b/vendor/woocommerce/subscriptions-core/assets/js/admin/admin.js index 9645d2c..b8c7956 100644 --- a/vendor/woocommerce/subscriptions-core/assets/js/admin/admin.js +++ b/vendor/woocommerce/subscriptions-core/assets/js/admin/admin.js @@ -1428,4 +1428,9 @@ jQuery( function ( $ ) { ); } } ); + + // On the subscriptions list table empty state screen, add the is-busy class to the button when clicked. + $( '.woo_subscriptions_empty_state__button_container a' ).on( 'click', function ( e ) { + $( this ).addClass( 'is-busy' ); + } ); } ); diff --git a/vendor/woocommerce/subscriptions-core/changelog.txt b/vendor/woocommerce/subscriptions-core/changelog.txt index 2a5b3d9..89bf68d 100644 --- a/vendor/woocommerce/subscriptions-core/changelog.txt +++ b/vendor/woocommerce/subscriptions-core/changelog.txt @@ -1,5 +1,11 @@ *** WooCommerce Subscriptions Core Changelog *** += 6.2.0 - 2023-08-10 = +* Add - Introduce an updated empty state screen for the WooCommerce > Subscriptions list table. +* Fix - Ensure subscription checkout and cart block integrations are loaded on store environments where WooPayments is not enabled. +* Fix - Ensure the shipping phone number field is copied to subscriptions and their orders when copying address meta. +* Update - When HPOS is disabled, fetch subscriptions by customer_id using the user's subscription cache to improve performance. +* Dev - Deprecated the 'woocommerce_subscriptions_not_found_label' filter. = 6.1.0 - 2023-07-26 = * Fix - Resolved an issue that prevented the "Used for variations" checkbox to not be enabled on the edit product page load causing variations to be deleted erroneously. diff --git a/vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-empty-list-content-manager.php b/vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-empty-list-content-manager.php new file mode 100644 index 0000000..ca04872 --- /dev/null +++ b/vendor/woocommerce/subscriptions-core/includes/admin/class-wcs-admin-empty-list-content-manager.php @@ -0,0 +1,97 @@ +get_subscriptions_core_directory( 'templates/admin/' ) + ); + } + + // Backwards compatibility for the woocommerce_subscriptions_not_found_label filter. + if ( has_action( 'woocommerce_subscriptions_not_found_label' ) ) { + wcs_deprecated_hook( 'woocommerce_subscriptions_not_found_label', '6.2.0', 'woocommerce_subscriptions_not_found_content' ); + + /** + * Filters the HTML for the empty state. + * + * The woocommerce_subscriptions_not_found_label filter no longer makes sense as the HTML is now + * more complex - it is no longer just a string. For backwards compatibility we still filter the + * full content shown in the empty state. + * + * @deprecated 6.2.0 Use the woocommerce_subscriptions_not_found_html filter instead. + * @param string $content The HTML for the empty state. + */ + $content = apply_filters( 'woocommerce_subscriptions_not_found_label', $content ); + } + + /** + * Filters the HTML for the empty state. + * + * @since 6.2.0 + * @param string $html The HTML for the empty state. + */ + return apply_filters( 'woocommerce_subscriptions_not_found_content', $content ); + } + + /** + * Enqueues the scripts and styles for the empty state. + */ + public static function enqueue_scripts_and_styles() { + $screen = get_current_screen(); + + // Only enqueue the scripts on the admin subscriptions screen. + if ( ! $screen || 'edit-shop_subscription' !== $screen->id || ! self::should_display_empty_state() ) { + return; + } + + wp_register_style( + 'Woo-Subscriptions-Empty-State', + WC_Subscriptions_Core_Plugin::instance()->get_subscriptions_core_directory_url( 'assets/css/admin-empty-state.css' ), + [], + WC_Subscriptions_Core_Plugin::instance()->get_library_version() + ); + + wp_enqueue_style( 'Woo-Subscriptions-Empty-State' ); + } + + /** + * Determines if the empty state content should be displayed. + * + * Uses the `woocommerce_subscriptions_not_empty` filter to determine if subscriptions exist on the store. + * + * @return bool True if subscriptions don't exist and the empty state should be displayed, otherwise false. + */ + private static function should_display_empty_state() { + return ! (bool) apply_filters( 'woocommerce_subscriptions_not_empty', WC_Subscriptions_Core_Plugin::instance()->cache->cache_and_get( 'wcs_do_subscriptions_exist', 'wcs_do_subscriptions_exist' ) ); + } +} diff --git a/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php b/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php index 9bf515a..c6dd320 100644 --- a/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php +++ b/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-core-plugin.php @@ -16,7 +16,7 @@ class WC_Subscriptions_Core_Plugin { * The version of subscriptions-core library. * @var string */ - protected $library_version = '6.1.0'; // WRCS: DEFINED_VERSION. + protected $library_version = '6.2.0'; // WRCS: DEFINED_VERSION. /** * The subscription scheduler instance. @@ -133,6 +133,7 @@ public function init() { WCS_Dependent_Hook_Manager::init(); WCS_Admin_Product_Import_Export_Manager::init(); WC_Subscriptions_Frontend_Scripts::init(); + WCS_Admin_Empty_List_Content_Manager::init(); add_action( 'init', array( 'WC_Subscriptions_Synchroniser', 'init' ) ); add_action( 'after_setup_theme', array( 'WC_Subscriptions_Upgrader', 'init' ), 11 ); @@ -153,11 +154,9 @@ public function init() { // Initialise the cache. $this->cache = WCS_Cache_Manager::get_instance(); - if ( class_exists( 'Automattic\WooCommerce\Blocks\Package' ) && version_compare( \Automattic\WooCommerce\Blocks\Package::get_version(), '4.4.0', '>' ) ) { - // When WooCommerceBlocks is loaded, set up the Integration class. - add_action( 'woocommerce_blocks_loaded', array( $this, 'setup_blocks_integration' ) ); - add_action( 'woocommerce_blocks_loaded', array( 'WC_Subscriptions_Extend_Store_Endpoint', 'init' ) ); - } + // When WooCommerceBlocks is loaded, set up the Integration class. + add_action( 'woocommerce_blocks_loaded', array( $this, 'setup_blocks_integration' ) ); + add_action( 'woocommerce_blocks_loaded', array( 'WC_Subscriptions_Extend_Store_Endpoint', 'init' ) ); if ( ! $payment_gateways_handler::are_zero_total_subscriptions_allowed() ) { WC_Subscriptions_Gateway_Restrictions_Manager::init(); @@ -326,19 +325,6 @@ public function get_gateways_handler_class() { * @since 1.0.0 - Migrated from WooCommerce Subscriptions v4.0.0 */ public function register_order_types() { - $subscriptions_exist = $this->cache->cache_and_get( 'wcs_do_subscriptions_exist', 'wcs_do_subscriptions_exist' ); - - if ( true === (bool) apply_filters( 'woocommerce_subscriptions_not_empty', $subscriptions_exist ) ) { - $not_found_text = __( 'No Subscriptions found', 'woocommerce-subscriptions' ); - } else { - $not_found_text = '

' . __( 'Subscriptions will appear here for you to view and manage once purchased by a customer.', 'woocommerce-subscriptions' ) . '

'; - // translators: placeholders are opening and closing link tags - $not_found_text .= '

' . sprintf( __( '%1$sLearn more about managing subscriptions »%2$s', 'woocommerce-subscriptions' ), '', '' ) . '

'; - // translators: placeholders are opening and closing link tags - $not_found_text .= '

' . sprintf( __( '%1$sAdd a subscription product »%2$s', 'woocommerce-subscriptions' ), '', '' ) . '

'; - } - - $subscriptions_not_found_text = apply_filters( 'woocommerce_subscriptions_not_found_label', $not_found_text ); wc_register_order_type( 'shop_subscription', @@ -357,7 +343,7 @@ public function register_order_types() { 'view' => _x( 'View Subscription', 'custom post type setting', 'woocommerce-subscriptions' ), 'view_item' => _x( 'View Subscription', 'custom post type setting', 'woocommerce-subscriptions' ), 'search_items' => __( 'Search Subscriptions', 'woocommerce-subscriptions' ), - 'not_found' => $subscriptions_not_found_text, + 'not_found' => WCS_Admin_Empty_List_Content_Manager::get_content(), 'not_found_in_trash' => _x( 'No Subscriptions found in trash', 'custom post type setting', 'woocommerce-subscriptions' ), 'parent' => _x( 'Parent Subscriptions', 'custom post type setting', 'woocommerce-subscriptions' ), 'menu_name' => __( 'Subscriptions', 'woocommerce-subscriptions' ), @@ -560,6 +546,9 @@ public function update_notice( $plugin_data, $r ) { * @since 1.0.0 - Migrated from WooCommerce Subscriptions v4.0.0 */ public function setup_blocks_integration() { + if ( ! class_exists( 'Automattic\WooCommerce\Blocks\Package' ) || ! version_compare( \Automattic\WooCommerce\Blocks\Package::get_version(), '4.4.0', '>' ) ) { + return; + } /** * Filter the compatible blocks for WooCommerce Subscriptions. */ diff --git a/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-data-copier.php b/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-data-copier.php index b6930f5..5d4f04e 100644 --- a/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-data-copier.php +++ b/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-data-copier.php @@ -317,6 +317,7 @@ private function get_address_data() { '_shipping_state' => $this->from_object->get_shipping_state( 'edit' ), '_shipping_postcode' => $this->from_object->get_shipping_postcode( 'edit' ), '_shipping_country' => $this->from_object->get_shipping_country( 'edit' ), + '_shipping_phone' => $this->from_object->get_shipping_phone( 'edit' ), ] ); } diff --git a/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php b/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php index 7fc02aa..4cd73a0 100644 --- a/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php +++ b/vendor/woocommerce/subscriptions-core/includes/class-wc-subscriptions-extend-store-endpoint.php @@ -49,6 +49,10 @@ class WC_Subscriptions_Extend_Store_Endpoint { * @since 1.0.0 - Migrated from WooCommerce Subscriptions */ public static function init() { + if ( ! class_exists( 'Automattic\WooCommerce\Blocks\Package' ) || ! version_compare( \Automattic\WooCommerce\Blocks\Package::get_version(), '4.4.0', '>' ) ) { + return; + } + self::$schema = class_exists( 'Automattic\WooCommerce\StoreApi\StoreApi' ) ? Automattic\WooCommerce\StoreApi\StoreApi::container()->get( Automattic\WooCommerce\StoreApi\SchemaController::class ) : Package::container()->get( Automattic\WooCommerce\Blocks\StoreApi\SchemaController::class ); self::$money_formatter = function_exists( 'woocommerce_store_api_get_formatter' ) ? woocommerce_store_api_get_formatter( 'money' ) : Package::container()->get( ExtendRestApi::class )->get_formatter( 'money' ); self::$currency_formatter = function_exists( 'woocommerce_store_api_get_formatter' ) ? woocommerce_store_api_get_formatter( 'currency' ) : Package::container()->get( ExtendRestApi::class )->get_formatter( 'currency' ); diff --git a/vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php b/vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php index 24cbf7f..b1cddd3 100644 --- a/vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php +++ b/vendor/woocommerce/subscriptions-core/includes/wcs-order-functions.php @@ -106,6 +106,7 @@ function wcs_copy_order_address( $from_order, $to_order, $address_type = 'all' ) $to_order->set_shipping_state( $from_order->get_shipping_state() ); $to_order->set_shipping_postcode( $from_order->get_shipping_postcode() ); $to_order->set_shipping_country( $from_order->get_shipping_country() ); + $to_order->set_shipping_phone( $from_order->get_shipping_phone() ); } if ( 'all' === $address_type || 'billing' === $address_type ) { diff --git a/vendor/woocommerce/subscriptions-core/templates/admin/html-admin-empty-list-table.php b/vendor/woocommerce/subscriptions-core/templates/admin/html-admin-empty-list-table.php new file mode 100644 index 0000000..46c29f0 --- /dev/null +++ b/vendor/woocommerce/subscriptions-core/templates/admin/html-admin-empty-list-table.php @@ -0,0 +1,20 @@ + +
+
+ +

+
+ +
+
+
+ diff --git a/vendor/woocommerce/subscriptions-core/wcs-functions.php b/vendor/woocommerce/subscriptions-core/wcs-functions.php index 80701de..1752ac1 100644 --- a/vendor/woocommerce/subscriptions-core/wcs-functions.php +++ b/vendor/woocommerce/subscriptions-core/wcs-functions.php @@ -501,7 +501,13 @@ function wcs_get_subscriptions( $args ) { // Maybe filter to a specific customer. if ( 0 !== $args['customer_id'] && is_numeric( $args['customer_id'] ) ) { - $query_args['customer_id'] = $args['customer_id']; + // When HPOS is disabled, fetch subscriptions by customer_id using the user's subscription cache and query by post__in for improved performance. + if ( ! wcs_is_custom_order_tables_usage_enabled() ) { + $users_subscription_ids = WCS_Customer_Store::instance()->get_users_subscription_ids( $args['customer_id'] ); + $query_args = WCS_Admin_Post_Types::set_post__in_query_var( $query_args, $users_subscription_ids ); + } else { + $query_args['customer_id'] = $args['customer_id']; + } } // We need to restrict subscriptions to those which contain a certain product/variation diff --git a/vendor/woocommerce/subscriptions-core/woocommerce-subscriptions-core.php b/vendor/woocommerce/subscriptions-core/woocommerce-subscriptions-core.php index a5d9bf9..931e1c0 100644 --- a/vendor/woocommerce/subscriptions-core/woocommerce-subscriptions-core.php +++ b/vendor/woocommerce/subscriptions-core/woocommerce-subscriptions-core.php @@ -6,5 +6,5 @@ * Author: Automattic * Author URI: https://woocommerce.com/ * Requires WP: 5.6 - * Version: 6.1.0 + * Version: 6.2.0 */ diff --git a/woocommerce-subscriptions.php b/woocommerce-subscriptions.php index e566619..b1c4023 100644 --- a/woocommerce-subscriptions.php +++ b/woocommerce-subscriptions.php @@ -5,10 +5,10 @@ * Description: Sell products and services with recurring payments in your WooCommerce Store. * Author: WooCommerce * Author URI: https://woocommerce.com/ - * Version: 5.3.1 + * Version: 5.4.0 * - * WC requires at least: 6.5 - * WC tested up to: 7.9.0 + * WC requires at least: 7.6.0 + * WC tested up to: 8.0.1 * Woo: 27147:6115e6d7e297b623a169fdcf5728b224 * * Copyright 2019 WooCommerce @@ -77,10 +77,10 @@ class WC_Subscriptions { public static $plugin_file = __FILE__; /** @var string */ - public static $version = '5.3.1'; // WRCS: DEFINED_VERSION. + public static $version = '5.4.0'; // WRCS: DEFINED_VERSION. /** @var string */ - public static $wc_minimum_supported_version = '6.5'; + public static $wc_minimum_supported_version = '7.6'; /** @var WCS_Cache_Manager */ public static $cache;