controller/common/src/Controller/Common/Subscription/Process/Processor/Email/Standard.php
public function end( \Aimeos\MShop\Subscription\Item\Iface $subscription )
	{
		$context = $this->getContext();

		$manager = \Aimeos\MShop::create( $context, 'order/base' );
		$baseItem = $manager->getItem( $subscription->getOrderBaseId(), ['order/base/address', 'order/base/product'] );

		$addrItem = $baseItem->getAddress( \Aimeos\MShop\Order\Item\Base\Address\Base::TYPE_PAYMENT, 0 );

		foreach( $baseItem->getProducts() as $orderProduct )
		{
			if( $orderProduct->getId() == $subscription->getOrderProductId() ) {
				$this->sendMail( $context, $subscription, $addrItem, $orderProduct );
			}
		}
	}
public function end( \Aimeos\MShop\Subscription\Item\Iface $subscription )
	{
		$context = $this->getContext();

		$manager = \Aimeos\MShop::create( $context, 'order/base' );
		$baseItem = $manager->getItem( $subscription->getOrderBaseId(), ['order/base/address', 'order/base/product'] );

		$addrItem = $baseItem->getAddress( \Aimeos\MShop\Order\Item\Base\Address\Base::TYPE_PAYMENT, 0 );

		foreach( $baseItem->getProducts() as $orderProduct )
		{
			if( $orderProduct->getId() == $subscription->getOrderProductId() ) {
				$this->sendMail( $context, $subscription, $addrItem, $orderProduct );
			}
		}
	}
public function end ( \ Aimeos \ MShop \ Subscription \ Item \ Iface $ subscription ) { $ context = $ this -> getContext ( ) ; $ manager = \ Aimeos \ MShop :: create ( $ context , 'order/base' ) ; $ baseItem = $ manager -> getItem ( $ subscription -> getOrderBaseId ( ) , [ 'order/base/address' , 'order/base/product' ] ) ; $ addrItem = $ baseItem -> getAddress ( \ Aimeos \ MShop \ Order \ Item \ Base \ Address \ Base :: TYPE_PAYMENT , 0 ) ; foreach ( $ baseItem -> getProducts ( ) as $ orderProduct ) { if ( $ orderProduct -> getId ( ) == $ subscription -> getOrderProductId ( ) ) { $ this -> sendMail ( $ context , $ subscription , $ addrItem , $ orderProduct ) ; } } }
Processes the end of the subscription

@param \Aimeos\MShop\Subscription\Item\Iface $subscription Subscription item
Processes the end of the subscription