order-load

Operator 'order-load' allows a module to load related data into the order.

Usually a module selects the data from it's own table(s) create by the .install file.
Use $arg1->order_id as the referring order id.

@param $op
  'order-load'
@param $arg1
  current order

@return
  NULL

<?php
case 'order-load':
 
$result = db_query("SELECT * FROM {uc_payment_cod} WHERE order_id = %d", $arg1->order_id);
  if (
$row = db_fetch_object($result)) {
   
$arg1->payment_details['delivery_month'] = $row->delivery_month;
   
$arg1->payment_details['delivery_day'] = $row->delivery_day;
   
$arg1->payment_details['delivery_year'] = $row->delivery_year;
  }
  break;
?>