WC_Email_Customer_Processing_Order::__constructpublicWC 1.0

Constructor.

Метод класса: WC_Email_Customer_Processing_Order{}

Хуков нет.

Возвращает

null. Ничего (null).

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

$WC_Email_Customer_Processing_Order = new WC_Email_Customer_Processing_Order();
$WC_Email_Customer_Processing_Order->__construct();

Код WC_Email_Customer_Processing_Order::__construct() WC 10.5.0

public function __construct() {
	$this->id             = 'customer_processing_order';
	$this->customer_email = true;

	$this->title          = __( 'Processing order', 'woocommerce' );
	$this->email_group    = 'order-updates';
	$this->template_html  = 'emails/customer-processing-order.php';
	$this->template_plain = 'emails/plain/customer-processing-order.php';
	$this->placeholders   = array(
		'{order_date}'   => '',
		'{order_number}' => '',
	);

	// Triggers for this email.
	add_action( 'woocommerce_order_status_cancelled_to_processing_notification', array( $this, 'trigger' ), 10, 2 );
	add_action( 'woocommerce_order_status_failed_to_processing_notification', array( $this, 'trigger' ), 10, 2 );
	add_action( 'woocommerce_order_status_on-hold_to_processing_notification', array( $this, 'trigger' ), 10, 2 );
	add_action( 'woocommerce_order_status_pending_to_processing_notification', array( $this, 'trigger' ), 10, 2 );

	// Call parent constructor.
	parent::__construct();

	// Must be after parent's constructor which sets `email_improvements_enabled` property.
	$this->description = $this->email_improvements_enabled
		? __( 'Send an email to customers notifying them that their order is being processed', 'woocommerce' )
		: __( 'This is an order notification sent to customers containing order details after payment.', 'woocommerce' );

	if ( $this->block_email_editor_enabled ) {
		$this->title       = __( 'Order confirmation', 'woocommerce' );
		$this->description = __( 'Notifies customers when their order has been received and is being processed.', 'woocommerce' );
	}
}