hook_alloc_build_items

Definition

hook_alloc_build_items($item, $op = 'process')
ecommerce-5--4/docs/developer/hooks/ec_receipt.php, line 358

Description

tba (example is from store.module)

Related topics

Namesort iconDescription
HooksAllow modules to interact with the Drupal core.

Code

<?php
function hook_alloc_build_items($item, $op = 'process') {
  static $txn;
  if ($op == 'init') {
    $txn = $item;
    return;
  }

  return array(
    'id' => $item->nid,
    'name' => $item->title,
    'qty' => $item->qty,
    'amount' => store_adjust_misc($txn, $item),
  );
}
?>