mirror of
https://github.com/pronamic/woocommerce-subscriptions.git
synced 2025-10-18 15:22:57 +00:00
Updates to 7.8.1
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
*** WooCommerce Subscriptions Changelog ***
|
||||
|
||||
2025-08-25 - version 7.8.1
|
||||
* Fix: Fix checkout button default label.
|
||||
* Fix: Fix error when WP CLI is enabled in some environments.
|
||||
|
||||
2025-08-19 - version 7.8.0
|
||||
* Add: Native support for subscriptions gifting. Gifting for WooCommerce Subscriptions extension is no longer required.
|
||||
* Add: Enable subscriptions gifting storewide and per product.
|
||||
|
@@ -318,10 +318,14 @@ class WC_Subscriptions_Plugin extends WC_Subscriptions_Core_Plugin {
|
||||
// Note that flags such as `--no-color` are filtered out of this array.
|
||||
$args = WP_CLI::get_runner()->arguments;
|
||||
|
||||
if ( ! is_countable( $args ) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (
|
||||
count( $args ) < 3
|
||||
|| $args[0] !== 'plugin'
|
||||
|| $args[1] !== 'activate'
|
||||
( count( $args ) < 3
|
||||
|| 'plugin' !== $args[0]
|
||||
|| 'activate' !== $args[1] )
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
|
@@ -37,7 +37,7 @@ class WCS_Call_To_Action_Button_Text_Manager {
|
||||
),
|
||||
array(
|
||||
'name' => __( 'Add to Cart Button Text', 'woocommerce-subscriptions' ),
|
||||
'desc' => __( 'A product displays a button with the text "Add to cart". By default, a subscription changes this to "Sign up now". You can customise the button text for subscriptions here.', 'woocommerce-subscriptions' ),
|
||||
'desc' => __( 'A product displays a button with the text "Add to cart". You can customise the button text for subscriptions here.', 'woocommerce-subscriptions' ),
|
||||
'tip' => '',
|
||||
'id' => WC_Subscriptions_Admin::$option_prefix . '_add_to_cart_button_text',
|
||||
'css' => 'min-width:150px;',
|
||||
@@ -48,14 +48,14 @@ class WCS_Call_To_Action_Button_Text_Manager {
|
||||
),
|
||||
array(
|
||||
'name' => __( 'Place Order Button Text', 'woocommerce-subscriptions' ),
|
||||
'desc' => __( 'Use this field to customise the text displayed on the checkout button when an order contains a subscription. Normally the checkout submission button displays "Place order". When the cart contains a subscription, this is changed to "Sign up now".', 'woocommerce-subscriptions' ),
|
||||
'desc' => __( 'Use this field to customise the text displayed on the checkout button when an order contains a subscription.', 'woocommerce-subscriptions' ),
|
||||
'tip' => '',
|
||||
'id' => WC_Subscriptions_Admin::$option_prefix . '_order_button_text',
|
||||
'css' => 'min-width:150px;',
|
||||
'default' => __( 'Add to cart', 'woocommerce-subscriptions' ),
|
||||
'default' => __( 'Place order', 'woocommerce-subscriptions' ),
|
||||
'type' => 'text',
|
||||
'desc_tip' => true,
|
||||
'placeholder' => __( 'Add to cart', 'woocommerce-subscriptions' ),
|
||||
'placeholder' => __( 'Place order', 'woocommerce-subscriptions' ),
|
||||
),
|
||||
array(
|
||||
'type' => 'sectionend',
|
||||
|
@@ -656,13 +656,13 @@ class WC_Subscriptions_Checkout {
|
||||
}
|
||||
|
||||
/**
|
||||
* Filter the "Add to cart" button text for subscription carts.
|
||||
* Filter the "Place order" button text for subscription carts.
|
||||
*
|
||||
* @since 7.8.0
|
||||
* @param string $button_text The "Add to cart" button text.
|
||||
* @return string The "Add to cart" button text.
|
||||
* @param string $button_text The "Place order" button text.
|
||||
* @return string The "Place order" button text.
|
||||
*/
|
||||
return apply_filters( 'wcs_place_subscription_order_text', __( 'Add to cart', 'woocommerce-subscriptions' ) );
|
||||
return apply_filters( 'wcs_place_subscription_order_text', __( 'Place order', 'woocommerce-subscriptions' ) );
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -67,9 +67,11 @@ class WCSG_Admin_Welcome_Announcement {
|
||||
*/
|
||||
public static function output_tour() {
|
||||
$screen = get_current_screen();
|
||||
// phpcs:ignore WordPress.Security.NonceVerification.Recommended
|
||||
$dashboard_path = isset( $_GET['path'] ) ? wc_clean( wp_unslash( $_GET['path'] ) ) : '';
|
||||
|
||||
// Only load on WooCommerce admin pages
|
||||
if ( ! $screen || 'woocommerce_page_wc-admin' !== $screen->id ) {
|
||||
if ( ! $screen || 'woocommerce_page_wc-admin' !== $screen->id || '/setup-wizard' === $dashboard_path ) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
@@ -167,6 +167,10 @@ class WCSG_Email {
|
||||
*/
|
||||
public static function maybe_remove_wc_new_customer_email( $customer_id, $new_customer_data ) {
|
||||
|
||||
if ( ! WC()->cart || ! WC()->cart->cart_contents ) {
|
||||
return;
|
||||
}
|
||||
|
||||
foreach ( WC()->cart->cart_contents as $key => $item ) {
|
||||
if ( ! empty( $item['wcsg_gift_recipients_email'] ) ) {
|
||||
if ( $item['wcsg_gift_recipients_email'] == $new_customer_data['user_email'] ) { // phpcs:ignore WordPress.PHP.StrictComparisons.LooseComparison
|
||||
@@ -185,6 +189,10 @@ class WCSG_Email {
|
||||
*/
|
||||
public static function maybe_reattach_wc_new_customer_email( $customer_id, $new_customer_data ) {
|
||||
|
||||
if ( ! WC()->cart || ! WC()->cart->cart_contents ) {
|
||||
return;
|
||||
}
|
||||
|
||||
foreach ( WC()->cart->cart_contents as $key => $item ) {
|
||||
if ( ! empty( $item['wcsg_gift_recipients_email'] ) ) {
|
||||
if ( $item['wcsg_gift_recipients_email'] == $new_customer_data['user_email'] ) { // phpcs:ignore WordPress.PHP.StrictComparisons.LooseComparison
|
||||
@@ -222,6 +230,10 @@ class WCSG_Email {
|
||||
* @param bool $password_generated Whether the password has been generated for the customer.
|
||||
*/
|
||||
public static function send_new_recipient_user_email( $customer_id, $new_customer_data, $password_generated ) {
|
||||
if ( ! WC()->cart || ! WC()->cart->cart_contents ) {
|
||||
return;
|
||||
}
|
||||
|
||||
foreach ( WC()->cart->cart_contents as $key => $item ) {
|
||||
if ( isset( $item['wcsg_gift_recipients_email'] ) ) {
|
||||
if ( $item['wcsg_gift_recipients_email'] === $new_customer_data['user_email'] ) {
|
||||
|
@@ -2,14 +2,14 @@
|
||||
# This file is distributed under the GNU General Public License v3.0.
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WooCommerce Subscriptions 7.8.0\n"
|
||||
"Project-Id-Version: WooCommerce Subscriptions 7.8.1\n"
|
||||
"Report-Msgid-Bugs-To: https://woocommerce.com/contact-us\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"POT-Creation-Date: 2025-08-19T23:58:38+00:00\n"
|
||||
"POT-Creation-Date: 2025-08-25T23:35:15+00:00\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"X-Generator: WP-CLI 2.11.0\n"
|
||||
"X-Domain: woocommerce-subscriptions\n"
|
||||
@@ -1109,14 +1109,11 @@ msgid "Add to Cart Button Text"
|
||||
msgstr ""
|
||||
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:40
|
||||
msgid "A product displays a button with the text \"Add to cart\". By default, a subscription changes this to \"Sign up now\". You can customise the button text for subscriptions here."
|
||||
msgid "A product displays a button with the text \"Add to cart\". You can customise the button text for subscriptions here."
|
||||
msgstr ""
|
||||
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:44
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:47
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:55
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:58
|
||||
#: includes/core/class-wc-subscriptions-checkout.php:665
|
||||
#: includes/core/class-wc-subscriptions-product.php:1246
|
||||
#: includes/core/class-wc-subscriptions-product.php:1278
|
||||
msgid "Add to cart"
|
||||
@@ -1127,7 +1124,13 @@ msgid "Place Order Button Text"
|
||||
msgstr ""
|
||||
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:51
|
||||
msgid "Use this field to customise the text displayed on the checkout button when an order contains a subscription. Normally the checkout submission button displays \"Place order\". When the cart contains a subscription, this is changed to \"Sign up now\"."
|
||||
msgid "Use this field to customise the text displayed on the checkout button when an order contains a subscription."
|
||||
msgstr ""
|
||||
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:55
|
||||
#: includes/class-wcs-call-to-action-button-text-manager.php:58
|
||||
#: includes/core/class-wc-subscriptions-checkout.php:665
|
||||
msgid "Place order"
|
||||
msgstr ""
|
||||
|
||||
#: includes/class-wcs-customer-suspension-manager.php:32
|
||||
@@ -6348,13 +6351,13 @@ msgid "File %d"
|
||||
msgstr ""
|
||||
|
||||
#. Translators: placeholder is a subscription ID.
|
||||
#: includes/gifting/class-wcsg-email.php:390
|
||||
#: includes/gifting/class-wcsg-email.php:402
|
||||
msgctxt "Used in email heading before line items table, placeholder is subscription ID"
|
||||
msgid "Subscription #%s"
|
||||
msgstr ""
|
||||
|
||||
#. Translators: placeholder is an order ID.
|
||||
#: includes/gifting/class-wcsg-email.php:393
|
||||
#: includes/gifting/class-wcsg-email.php:405
|
||||
msgctxt "Used in email heading before line items table, placeholder is order ID"
|
||||
msgid "Order #%s"
|
||||
msgstr ""
|
||||
|
12
vendor/composer/installed.php
vendored
12
vendor/composer/installed.php
vendored
@@ -1,9 +1,9 @@
|
||||
<?php return array(
|
||||
'root' => array(
|
||||
'name' => 'woocommerce/woocommerce-subscriptions',
|
||||
'pretty_version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'reference' => '4a23cafa810efb0cd9cf4f9210285810e98a7525',
|
||||
'pretty_version' => 'dev-release/7.8.1',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'reference' => '27f35a5449bcd854523318e5a189af6c53876f14',
|
||||
'type' => 'wordpress-plugin',
|
||||
'install_path' => __DIR__ . '/../../',
|
||||
'aliases' => array(),
|
||||
@@ -29,9 +29,9 @@
|
||||
'dev_requirement' => false,
|
||||
),
|
||||
'woocommerce/woocommerce-subscriptions' => array(
|
||||
'pretty_version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'reference' => '4a23cafa810efb0cd9cf4f9210285810e98a7525',
|
||||
'pretty_version' => 'dev-release/7.8.1',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'reference' => '27f35a5449bcd854523318e5a189af6c53876f14',
|
||||
'type' => 'wordpress-plugin',
|
||||
'install_path' => __DIR__ . '/../../',
|
||||
'aliases' => array(),
|
||||
|
44
vendor/composer/jetpack_autoload_classmap.php
vendored
44
vendor/composer/jetpack_autoload_classmap.php
vendored
@@ -479,91 +479,91 @@ return array(
|
||||
'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-version-selector.php'
|
||||
),
|
||||
'WCSG_Admin' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-admin.php'
|
||||
),
|
||||
'WCSG_Admin_System_Status' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-admin-system-status.php'
|
||||
),
|
||||
'WCSG_Admin_Welcome_Announcement' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-admin-welcome-announcement.php'
|
||||
),
|
||||
'WCSG_Cart' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-cart.php'
|
||||
),
|
||||
'WCSG_Checkout' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-checkout.php'
|
||||
),
|
||||
'WCSG_Download_Handler' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-download-handler.php'
|
||||
),
|
||||
'WCSG_Email' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-email.php'
|
||||
),
|
||||
'WCSG_Email_Completed_Renewal_Order' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/emails/class-wcsg-email-completed-renewal-order.php'
|
||||
),
|
||||
'WCSG_Email_Customer_New_Account' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/emails/class-wcsg-email-customer-new-account.php'
|
||||
),
|
||||
'WCSG_Email_Processing_Renewal_Order' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/emails/class-wcsg-email-processing-renewal-order.php'
|
||||
),
|
||||
'WCSG_Email_Recipient_New_Initial_Order' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/emails/class-wcsg-email-recipient-new-initial-order.php'
|
||||
),
|
||||
'WCSG_Memberships_Integration' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-memberships-integration.php'
|
||||
),
|
||||
'WCSG_Privacy' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/privacy/class-wcsg-privacy.php'
|
||||
),
|
||||
'WCSG_Privacy_Erasers' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/privacy/class-wcsg-privacy-erasers.php'
|
||||
),
|
||||
'WCSG_Privacy_Exporters' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/privacy/class-wcsg-privacy-exporters.php'
|
||||
),
|
||||
'WCSG_Product' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-product.php'
|
||||
),
|
||||
'WCSG_Query' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-query.php'
|
||||
),
|
||||
'WCSG_Recipient_Addresses' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-recipient-addresses.php'
|
||||
),
|
||||
'WCSG_Recipient_Details' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-recipient-details.php'
|
||||
),
|
||||
'WCSG_Recipient_Management' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-recipient-management.php'
|
||||
),
|
||||
'WCSG_Template_Loader' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcsg-template-loader.php'
|
||||
),
|
||||
'WCS_Gifting' => array(
|
||||
'version' => 'dev-release/7.8.0',
|
||||
'version' => 'dev-release/7.8.1',
|
||||
'path' => $baseDir . '/includes/gifting/class-wcs-gifting.php'
|
||||
),
|
||||
);
|
||||
|
@@ -5,7 +5,7 @@
|
||||
* Description: Sell products and services with recurring payments in your WooCommerce Store.
|
||||
* Author: WooCommerce
|
||||
* Author URI: https://woocommerce.com/
|
||||
* Version: 7.8.0
|
||||
* Version: 7.8.1
|
||||
* Requires Plugins: woocommerce
|
||||
*
|
||||
* WC requires at least: 9.8.5
|
||||
@@ -74,7 +74,7 @@ class WC_Subscriptions {
|
||||
public static $plugin_file = __FILE__;
|
||||
|
||||
/** @var string */
|
||||
public static $version = '7.8.0'; // WRCS: DEFINED_VERSION.
|
||||
public static $version = '7.8.1'; // WRCS: DEFINED_VERSION.
|
||||
|
||||
/** @var string */
|
||||
public static $wc_minimum_supported_version = '7.7';
|
||||
|
Reference in New Issue
Block a user