Automattic\WooCommerce\Blocks\Domain\Services

CreateAccount{}WC 1.0

Устарела с версии This class can't be removed due to https://github.com/woocommerce/woocommerce/issues/52311.. Больше не поддерживается и может быть удалена. Рекомендуется заменить эту функцию на аналог.

Service class implementing new create account emails used for order processing via the Block Based Checkout.

Хуков нет.

Использование

$CreateAccount = new CreateAccount();
// use class methods

Методы

  1. public __construct( Package $package )
  2. public customer_new_account( $customer_id = 0, array $new_customer_data = array() )
  3. public init()
  4. ERROR: no method name found on line ``
  5. ERROR: no method name found on line ``
  6. ERROR: no method name found on line `*`
  7. ERROR: no method name found on line ``
  8. ERROR: no method name found on line ``
  9. ERROR: no method name found on line ``
  10. ERROR: no method name found on line ``
  11. ERROR: no method name found on line ``

Список изменений

Устарела This class can't be removed due to https://github.com/woocommerce/woocommerce/issues/52311.

Код CreateAccount{} WC 10.8.1

class CreateAccount {
	/**
	 * Reference to the Package instance
	 *
	 * @var Package
	 */
	private $package;

	/**
	 * Constructor.
	 *
	 * @param Package $package An instance of (Woo Blocks) Package.
	 */
	public function __construct( Package $package ) {
		$this->package = $package;
	}

	/**
	 * Init - register handlers for WooCommerce core email hooks.
	 */
	public function init() {
		// This method is intentionally left blank.
	}

	/**
	 * Trigger new account email.
	 *
	 * @param int   $customer_id       The ID of the new customer account.
	 * @param array $new_customer_data Assoc array of data for the new account.
	 */
	public function customer_new_account( $customer_id = 0, array $new_customer_data = array() ) {
		// This method is intentionally left blank.
	}
}