You are here

function theme_invoice_body in Invoice 6

Same name and namespace in other branches
  1. 7 invoice.module \theme_invoice_body()

Theme function for displaying the invoice

2 theme calls to theme_invoice_body()
invoice_view in ./invoice.module
Implementation of hook_view()
_invoice_get_html in ./invoice_helpers.inc
Helper function to get the invoice in HTML format

File

./invoice.module, line 857
Invoice module

Code

function theme_invoice_body($node, $type = NULL) {
  $content = '<div class="invoice-wrapper">';
  require_once dirname(__FILE__) . '/templates/' . $node->invoice['template'] . '.inc';
  drupal_add_css(drupal_get_path('module', 'invoice') . '/templates/' . $node->invoice['template'] . '.css', 'module');
  $content_function = '_invoice_' . $node->invoice['template'] . '_get_template_output';
  $content .= $content_function($node, $type);
  $content .= '</div>';
  return $content;
}