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

shop:onGetOrderItemDisplayDetails event

Triggered by Shop_OrderItem
Author LemonStand eCommerce Inc.

Event handler signature

public string event_onGetOrderItemDisplayDetails(Shop_OrderItem $item, boolean $as_plain_text)
$item Shop_OrderItem specifies the order item object.
$as_plain_text boolean determines whether the result should be in HTML or plain text format.
{return} string returns the order item description string.
Allows to display custom information about an order item in the Administration Area, for example on the Order Preview page. Below is an event handler example. Similar code used in the Subscriptions Module:
public function subscribeEvents()
{
  Backend::$events->addEvent('shop:onGetOrderItemDisplayDetails', $this, 'get_order_item_details');
}

public function get_order_item_details($item, $as_plain_text)
{
  if ($item->x_subscription_start_date && $item->x_subscription_end_date)
    return 'Subscription: '.
      $item->x_subscription_start_date->format('%x').' - '.$item->x_subscription_end_date->format('%x');

  return 'Subscription start date is undefined until the order is paid.';
}