<?php
/**
 * Subscription Renewed Email
 * Sent to customer after a successful renewal payment.
 *
 * @package GGM_Commerce
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

class GGM_Commerce_Email_Subscription_Renewed extends GGM_Commerce_Email_Subscription_Template {

	public function __construct() {
		$this->id             = 'subscription_renewed';
		$this->title          = __( 'Subscription Renewed', 'ggm-commerce' );
		$this->description    = __( 'Sent to the customer after a successful recurring payment.', 'ggm-commerce' );
		$this->recipient_type = 'customer';
	}

	public function get_default_subject() {
		return __( 'Subscription #{subscription_number} renewed successfully', 'ggm-commerce' );
	}

	public function get_default_heading() {
		return __( 'Subscription Renewed', 'ggm-commerce' );
	}

	public function get_default_content() {
		return '
<p>Hi {customer_first_name},</p>

<p>Your subscription has been renewed successfully. A payment of {subscription_amount} has been charged to your {subscription_payment_method} account.</p>
' . $this->render_subscription_details_block() . '

<p>Your next payment will be on {subscription_next_payment}.</p>

<p>Thank you for your continued subscription!</p>
';
	}
}
