After patch from miimooo.

This commit is contained in:
mattbk
2015-10-06 13:59:53 -05:00
parent bb1313bad9
commit efefb7cd23
51 changed files with 427 additions and 741 deletions

View File

@ -1,4 +1,5 @@
<?php
// $Id: theme.inc,v 1.1.2.2 2010/04/09 18:52:38 hanoii Exp $
/**
* @file
@ -11,15 +12,11 @@
function template_preprocess_uc_views_view_row_invoice(&$vars) {
require_once drupal_get_path('module', 'uc_order') . '/uc_order.admin.inc';
$order_id = $vars['row']->{$vars['field_alias']};
if (module_exists('uc_credit')) {
// Clear credit cache, otherwise the load function below will return
// the same cached credit information for all the subsequent orders
// invoices
uc_credit_cache('clear');
}
// Clear credit cache, otherwise the load function below will return
// the same cached credit information for all the subsequent orders inovoices
uc_credit_cache('clear');
$order = uc_order_load($order_id);
$invoice = uc_order_invoice($order);
$vars['invoice'] = $invoice;
}
}