'; if ($type == 'sent') { $title = t('Items I requested from people'); } else { $title = t('My items that people requested'); } $output .= '

'. $title .'

'; if (empty($transactions)) { $output .= t('There are no transactions.'); $output .= ''; return $output; } foreach($transactions as $transaction) { foreach (muamba_actions_available($type, $transaction['status']) as $action) { $callback = muamba_actions($action); $actions[] = l(t($callback), $callback); } $rows[] = array( 'asset' => $transaction['node']->title, 'user' => $transaction['user']->name, 'status' => t(muamba_statuses($transaction['status'])), 'actions' => implode($actions, ' | '), 'thread' => l(t('view'), 'messages/view/'. $transaction['thread_id']), ); } // Make a table for them. $header = array(t('Asset'), t('User'), t('Status'), t('Actions'), t('Messages')); $output .= theme('table', array('header' => $header, 'rows' => $rows)); $output .= ''; return $output; }