This is the API docs for LemonStand V1, which has been discontinued. LemonStand is now a cloud based platform, available at lemonstand.com.

LemonStand API

onDeleteEmailTemplate event

Triggered by System_EmailTemplate
Author LemonStand eCommerce Inc.

Event handler signature

public void event_onDeleteEmailTemplate(System_EmailTemplate $template)
$template System_EmailTemplate the email template object.
Triggered when a user tries to delete an email template in the Administration Area. The handler can throw an exception to cancel the template deletion. Example:
public function subscribeEvents()
{
  Backend::$events->addEvent('onDeleteEmailTemplate', $this, 'process_template_deletion');
}

public function process_template_deletion($template)
{
  if ($template->code == 'payment_notificaiton')
    throw new Phpr_ApplicationException('You cannot delete this email template.');
}