# Bazaar merge directive format 2 (Bazaar 0.90) # revision_id: lyle@ubercart.org-20090413143457-qtnw8cxgnte9r457 # target_branch: bzr+ssh://lyle.mantooth@bazaar.ubercart.org/bzr\ # /drupal6/ubercart/ # testament_sha1: 72b6eaa2f55ea8581ad84b49755d0e44f8c2da88 # timestamp: 2009-04-13 10:40:47 -0400 # base_revision_id: ryan@ubercart.org-20090412021138-wwgusm90fumx9aud # # Begin patch === modified file 'ca/ca.module' --- ca/ca.module 2009-04-07 18:22:28 +0000 +++ ca/ca.module 2009-04-13 14:26:56 +0000 @@ -156,6 +156,10 @@ * TRUE or FALSE indicating if at least one predicate was evaluated. */ function ca_pull_trigger() { + // Trigger actions can pull other triggers. Lock predicates when they are + // marked for evaluation so they can't be evaluated again. + static $locked; + $args = func_get_args(); $trigger = array_shift($args); @@ -185,11 +189,17 @@ // Loop through the predicates and evaluate them one by one. foreach ($predicates as $pid => $predicate) { - // If all of a predicate's conditions evaluate to TRUE... - if (ca_evaluate_conditions($predicate, $arguments)) { - // Then perform its actions. - ca_perform_actions($predicate, $arguments); + // Prevent the predicate from being evaluated if it already has been with + // the same arguments. + $key = $pid . serialize($arguments); + if (!isset($locked[$key])) { + // If all of a predicate's conditions evaluate to TRUE... + if (ca_evaluate_conditions($predicate, $arguments)) { + // Then perform its actions. + ca_perform_actions($predicate, $arguments); + } } + $locked[$key] = TRUE; } return TRUE; @@ -247,10 +257,6 @@ * An array of predicates. */ function ca_load_trigger_predicates($trigger, $all = FALSE) { - // Trigger actions can pull other triggers. Lock predicates when they are - // marked for evaluation so they can't be evaluated again. - static $locked = array(); - // Load all the module defined predicates. $predicates = module_invoke_all('ca_predicate'); @@ -266,18 +272,8 @@ if (!$all && $value['#status'] <= 0) { unset($predicates[$key]); } - else { - // Prevent predicates from being evaluated more than once in a page load. - if (in_array($key, $locked)) { - unset($predicates[$key]); - } - else { - $locked[$key] = $key; - } - - if (!isset($value['#weight'])) { - $predicates[$key]['#weight'] = 0; - } + elseif (!isset($value['#weight'])) { + $predicates[$key]['#weight'] = 0; } } @@ -288,28 +284,22 @@ // these, we unset the module defined predicate and reconsider adding it in. if (!is_numeric($data['pid'])) { unset($predicates[$data['pid']]); - unset($locked[$data['pid']]); } // Add predicates from the database to our return array if $all == TRUE or // if the predicate is active. if ($all || $data['status'] > 0) { - // Prevent predicates from being evaluated more than once in a page load. - if (!in_array($data['pid'], $locked)) { - $predicate = ca_prepare_db_predicate($data); + $predicate = ca_prepare_db_predicate($data); - // Set the actions' weight if necessary and sort actions by their weight. - for ($i = 0; $i < count($predicate['#actions']); $i++) { - if (!isset($predicate['#actions'][$i]['#weight'])) { - $predicate['#actions'][$i]['#weight'] = 0; - } + // Set the actions' weight if necessary and sort actions by their weight. + for ($i = 0; $i < count($predicate['#actions']); $i++) { + if (!isset($predicate['#actions'][$i]['#weight'])) { + $predicate['#actions'][$i]['#weight'] = 0; } - usort($predicate['#actions'], 'ca_weight_sort'); - - $predicates[$data['pid']] = $predicate; - - $locked[$key] = $data['pid']; } + usort($predicate['#actions'], 'ca_weight_sort'); + + $predicates[$data['pid']] = $predicate; } } === modified file 'payment/uc_payment/uc_payment.admin.inc' --- payment/uc_payment/uc_payment.admin.inc 2009-02-10 21:51:13 +0000 +++ payment/uc_payment/uc_payment.admin.inc 2009-04-13 14:34:21 +0000 @@ -297,10 +297,22 @@ $total = $order->order_total; $payments = uc_payment_load_payments($order->order_id); - $form['order_total'] = array('#value' => uc_currency_format($total)); + $context = array( + 'revision' => 'formatted', + 'location' => 'order-payments-admin', + 'subject' => array( + 'order' => $order, + 'total' => $total, + ), + ); + $form['order_total'] = array('#value' => uc_price($total, $context)); $form['payments'] = tapir_get_table('uc_payments_table'); + $context = array( + + ); if ($payments !== FALSE) { foreach ($payments as $payment) { + $context['subject']['payment'] = $payment; $form['payments'][$payment->receipt_id]['#attributes'] = array('valign' => 'top'); $form['payments'][$payment->receipt_id]['received'] = array( '#value' => format_date($payment->received, 'custom', variable_get('uc_date_format_default', 'm/d/Y') .'H:i:s'), @@ -312,11 +324,13 @@ '#value' => ($payment->method == '') ? t('Unknown') : $payment->method, ); $form['payments'][$payment->receipt_id]['amount'] = array( - '#value' => uc_currency_format($payment->amount), + '#value' => uc_price($payment->amount, $context), ); $total -= $payment->amount; + unset($context['subject']['payment']); + $context['subject']['total'] = $total; $form['payments'][$payment->receipt_id]['balance'] = array( - '#value' => uc_currency_format($total), + '#value' => uc_price($total, $context, array('cache' => FALSE)), ); $form['payments'][$payment->receipt_id]['comment'] = array( '#value' => ($payment->comment == '') ? '-' : filter_xss_admin($payment->comment), @@ -333,7 +347,8 @@ ); } } - $form['balance'] = array('#value' => uc_currency_format($total)); + $context['revision'] = 'formatted'; + $form['balance'] = array('#value' => uc_price($total, $context)); $form['order_id'] = array( '#type' => 'hidden', '#value' => $order->order_id, === modified file 'payment/uc_payment/uc_payment.module' --- payment/uc_payment/uc_payment.module 2008-12-08 17:05:35 +0000 +++ payment/uc_payment/uc_payment.module 2009-04-13 14:34:21 +0000 @@ -326,18 +326,28 @@ .' '; $grand_total = 0; + $context = array( + 'location' => 'checkout-order-total-preview', + ); + foreach ($totals as $line) { if (!empty($line[2])) { + $context['subject'] = array( + 'line_item' => $line, + ); $output .= '' - .''; + .''; if ($line[3]) { $grand_total += round($line[1], 2); } } } + $context['subject'] = array( + 'grand_total' => $grand_total, + ); $output .= '' - .'
'. $line[2] .':'. uc_currency_format($line[1]) .'
'. uc_price($line[1], $context) .'
'. t('Order total:') .''. uc_currency_format($grand_total) + .''. uc_price($grand_total, $context) .'
'; } === modified file 'payment/uc_payment/uc_payment_checkout_pane.inc' --- payment/uc_payment/uc_payment_checkout_pane.inc 2008-11-05 22:41:07 +0000 +++ payment/uc_payment/uc_payment_checkout_pane.inc 2009-04-13 14:34:21 +0000 @@ -100,8 +100,14 @@ } } usort($line_items, 'uc_weight_sort'); + + $context = array( + 'revision' => 'formatted', + 'location' => 'checkout-review-line-item', + ); foreach ($line_items as $line_item) { - $review[] = array('title' => $line_item['title'], 'data' => uc_currency_format($line_item['amount'])); + $context['subject'] = array('line_item' => $line_item); + $review[] = array('title' => $line_item['title'], 'data' => uc_price($line_item['amount'], $context)); } $review_data = _payment_method_data($arg1->payment_method, 'review'); if (empty($review_data)) { === modified file 'payment/uc_payment/uc_payment_order_pane.inc' --- payment/uc_payment/uc_payment_order_pane.inc 2008-11-07 20:19:07 +0000 +++ payment/uc_payment/uc_payment_order_pane.inc 2009-04-13 14:34:21 +0000 @@ -18,7 +18,14 @@ switch ($op) { case 'view': if (variable_get('uc_payment_tracking', TRUE)) { - $output = t('Balance: @balance', array('@balance' => uc_currency_format(uc_payment_balance($arg1)))); + $context = array( + 'revision' => 'formatted', + 'location' => 'payment-balance', + 'subject' => array( + 'order' => $arg1, + ), + ); + $output = t('Balance: @balance', array('@balance' => uc_price(uc_payment_balance($arg1), $context))); $output .= ' ('. l(t('View'), 'admin/store/orders/'. $arg1->order_id .'/payments') .')
'; } $method_name = _payment_method_data($arg1->payment_method, 'review'); === modified file 'shipping/uc_flatrate/uc_flatrate.admin.inc' --- shipping/uc_flatrate/uc_flatrate.admin.inc 2009-02-06 21:02:20 +0000 +++ shipping/uc_flatrate/uc_flatrate.admin.inc 2009-04-13 14:34:57 +0000 @@ -13,16 +13,23 @@ function uc_flatrate_admin_methods() { $output = ''; + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-flatrate-method-admin', + ); + $rows = array(); $enabled = variable_get('uc_quote_enabled', array()); $weight = variable_get('uc_quote_method_weight', array()); $result = db_query("SELECT mid, title, label, base_rate, product_rate FROM {uc_flatrate_methods}"); while ($method = db_fetch_object($result)) { + $context['subject']['flatrate_method'] = $method; + $row = array(); $row[] = check_plain($method->title); $row[] = check_plain($method->label); - $row[] = uc_currency_format($method->base_rate); - $row[] = uc_currency_format($method->product_rate); + $row[] = uc_price($method->base_rate, $context); + $row[] = uc_price($method->product_rate, $context); $row[] = l(t('edit'), 'admin/store/settings/quotes/methods/flatrate/'. $method->mid); $row[] = l(t('conditions'), CA_UI_PATH .'/uc_flatrate_get_quote_'. $method->mid .'/edit/conditions'); $rows[] = $row; === modified file 'shipping/uc_flatrate/uc_flatrate.module' --- shipping/uc_flatrate/uc_flatrate.module 2009-02-12 15:33:59 +0000 +++ shipping/uc_flatrate/uc_flatrate.module 2009-04-13 14:34:57 +0000 @@ -55,7 +55,12 @@ $enabled = variable_get('uc_quote_enabled', array()); $weight = variable_get('uc_quote_method_weight', array()); $result = db_query("SELECT mid, title, product_rate FROM {uc_flatrate_methods}"); + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-flatrate-method-node-form', + ); while ($method = db_fetch_object($result)) { + $context['subject']['flatrate_method'] = $method; if (!isset($form['shipping']['flatrate'])) { $form['shipping']['flatrate'] = array( '#type' => 'fieldset', @@ -71,7 +76,7 @@ '#type' => 'textfield', '#title' => $method->title, '#default_value' => $form['#node']->flatrate[$method->mid], - '#description' => t('Default rate: %price', array('%price' => uc_currency_format($method->product_rate))), + '#description' => t('Default rate: %price', array('%price' => uc_price($method->product_rate, $context))), '#size' => 16, '#field_prefix' => $sign_flag ? '' : $currency_sign, '#field_suffix' => $sign_flag ? $currency_sign : '', @@ -201,7 +206,13 @@ function uc_flatrate_quote($products, $details, $method) { $method = explode('_', $method['id']); $mid = $method[1]; + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-flatrate-method-json', + ); + if ($method = db_fetch_object(db_query("SELECT * FROM {uc_flatrate_methods} WHERE mid = %d", $mid))) { + $context['subject']['flatrate_method'] = $method; // Start at the base rate. $rate = $method->base_rate; @@ -216,7 +227,7 @@ } } - $quotes[] = array('rate' => $rate, 'format' => uc_currency_format($rate), 'option_label' => check_plain($method->label)); + $quotes[] = array('rate' => $rate, 'format' => uc_price($rate, $context), 'option_label' => check_plain($method->label)); } return $quotes; === modified file 'shipping/uc_quote/uc_quote.module' --- shipping/uc_quote/uc_quote.module 2009-03-31 14:14:58 +0000 +++ shipping/uc_quote/uc_quote.module 2009-04-13 14:34:57 +0000 @@ -866,9 +866,14 @@ return TRUE; case 'review': + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-quote-checkout-pane-review', + ); $result = db_query("SELECT * FROM {uc_order_line_items} WHERE order_id = %d AND type = '%s'", $arg1->order_id, 'shipping'); if ($line_item = db_fetch_object($result)) { - $review[] = array('title' => $line_item->title, 'data' => uc_currency_format($line_item->amount)); + $context['subject']['line_item'] = $line_item; + $review[] = array('title' => $line_item->title, 'data' => uc_price($line_item->amount, $context)); } return $review; } === modified file 'shipping/uc_shipping/uc_shipping.admin.inc' --- shipping/uc_shipping/uc_shipping.admin.inc 2009-04-01 13:40:52 +0000 +++ shipping/uc_shipping/uc_shipping.admin.inc 2009-04-13 14:34:57 +0000 @@ -587,7 +587,12 @@ else { $rows[] = array(t('Services:'), $shipment->accessorials); } - $rows[] = array(t('Cost:'), uc_currency_format($shipment->cost)); + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-order-view', + 'subject' => array('shipment' => $shipment), + ); + $rows[] = array(t('Cost:'), uc_price($shipment->cost, $context)); $output .= theme('table', array(), $rows, array('style' => 'width:auto')); $output .= ''; foreach ($shipment->packages as $package) { === modified file 'shipping/uc_shipping/uc_shipping.module' --- shipping/uc_shipping/uc_shipping.module 2009-02-04 22:14:23 +0000 +++ shipping/uc_shipping/uc_shipping.module 2009-04-13 14:34:57 +0000 @@ -236,7 +236,12 @@ if ($package->length && $package->width && $package->height) { $rows[] = array(t('Dimensions:'), t('!l x !w x !h', array('!l' => uc_length_format($package->length), '!w' => uc_length_format($package->width), '!h' => uc_length_format($package->height)))); } - $rows[] = array(t('Insured value:'), uc_currency_format($package->value)); + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-package-view', + 'subject' => array('package' => $package), + ); + $rows[] = array(t('Insured value:'), uc_price($package->value, $context)); if ($package->tracking_number) { $rows[] = array(t('Tracking number:'), check_plain($package->tracking_number)); } === modified file 'shipping/uc_ups/uc_ups.admin.inc' --- shipping/uc_ups/uc_ups.admin.inc 2009-04-04 05:08:59 +0000 +++ shipping/uc_ups/uc_ups.admin.inc 2009-04-13 14:34:57 +0000 @@ -206,7 +206,12 @@ $output .= '
'; $method = uc_ups_shipping_method(); $output .= ''. $method['ups']['quote']['accessorials'][$_SESSION['ups']['service']] .'
'; - $output .= ''. check_plain($_SESSION['ups']['rate']['type']) .': '. uc_currency_format($_SESSION['ups']['rate']['amount']) .' ('. check_plain($_SESSION['ups']['rate']['currency']) .')
'; + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-ups-confirm', + 'subject' => array('ups_info' => $_SESSION['ups']), + ); + $output .= ''. check_plain($_SESSION['ups']['rate']['type']) .': '. uc_price($_SESSION['ups']['rate']['amount'], $context) .' ('. check_plain($_SESSION['ups']['rate']['currency']) .')
'; $ship_date = $_SESSION['ups']['ship_date']; $output .= 'Ship date: '. format_date(gmmktime(12, 0, 0, $ship_date['month'], $ship_date['day'], $ship_date['year']), 'custom', variable_get('uc_date_format_default', 'm/d/Y')); $exp_delivery = $_SESSION['ups']['expected_delivery']; === modified file 'shipping/uc_ups/uc_ups.module' --- shipping/uc_ups/uc_ups.module 2009-04-04 05:08:59 +0000 +++ shipping/uc_ups/uc_ups.module 2009-04-13 14:34:57 +0000 @@ -834,9 +834,14 @@ } } uasort($quotes, 'uc_quote_price_sort'); + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-quote', + ); foreach ($quotes as $key => $quote) { if (isset($quote['rate'])) { - $quotes[$key]['format'] = uc_currency_format($quote['rate']); + $context['subject']['quote'] = $quote; + $quotes[$key]['format'] = uc_price($quote['rate'], $context); $quotes[$key]['option_label'] = theme('uc_ups_option_label', $method['ups']['quote']['accessorials'][$key]); } } === modified file 'shipping/uc_usps/uc_usps.module' --- shipping/uc_usps/uc_usps.module 2009-02-12 15:33:59 +0000 +++ shipping/uc_usps/uc_usps.module 2009-04-13 14:34:57 +0000 @@ -399,9 +399,14 @@ unset($services[$service]); } } + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-usps-quote', + ); foreach ($services as $key => $quote) { if (isset($quote['rate'])) { - $services[$key]['format'] = uc_currency_format($quote['rate']); + $context['subject']['quote'] = $quote; + $services[$key]['format'] = uc_price($quote['rate'], $context); $services[$key]['option_label'] = $quote['label']; } } === modified file 'shipping/uc_weightquote/uc_weightquote.module' --- shipping/uc_weightquote/uc_weightquote.module 2009-02-12 15:33:59 +0000 +++ shipping/uc_weightquote/uc_weightquote.module 2009-04-13 14:34:57 +0000 @@ -182,7 +182,14 @@ $method = uc_weightquote_shipping_method(); - $quotes[] = array('rate' => $rate, 'format' => uc_currency_format($rate), 'option_label' => $method['weightquote']['quote']['accessorials'][0]); + $context = array( + 'revision' => 'formatted', + 'location' => 'shipping-weightquote-quote', + 'subject' => array( + 'method' => $method, + ), + ); + $quotes[] = array('rate' => $rate, 'format' => uc_price($rate, $context), 'option_label' => $method['weightquote']['quote']['accessorials'][0]); return $quotes; } === modified file 'uc_attribute/uc_attribute.module' --- uc_attribute/uc_attribute.module 2009-04-07 18:50:58 +0000 +++ uc_attribute/uc_attribute.module 2009-04-13 14:34:21 +0000 @@ -590,19 +590,35 @@ $form_attributes = array(); + $context = array( + 'revision' => 'formatted', + 'location' => 'product-attribute-form-element', + 'subject' => array(), + ); + // Loop through each product attribute and generate its form element. foreach ($attributes as $attribute) { + $context['subject']['attribute'] = $attribute; // Build the attribute's options array. $options = array(); foreach ($attribute->options as $option) { + $context['subject']['option'] = $option; switch (variable_get('uc_attribute_option_price_format', 'adjustment')) { case 'total': - $display_price = in_array($attribute->aid, $priced_attributes) ? ', '. uc_currency_format(($product->sell_price + $option->price) * $qty) : ''; + $price_info = array( + 'price' => $product->sell_price + $option->price, + 'qty' => $qty, + ); + $display_price = in_array($attribute->aid, $priced_attributes) ? ', '. uc_price($price_info, $context) : ''; if (count($priced_attributes) == 1) { break; } case 'adjustment': - $display_price = ($option->price != 0 ? ', '. ($option->price > 0 ? '+' : '') . uc_currency_format($option->price * $qty) : ''); + $price_info = array( + 'price' => $option->price, + 'qty' => $qty, + ); + $display_price = ($option->price != 0 ? ', '. ($option->price > 0 ? '+' : '') . uc_price($price_info, $context) : ''); break; case 'none': default: === modified file 'uc_cart/uc_cart.module' --- uc_cart/uc_cart.module 2009-04-01 16:39:58 +0000 +++ uc_cart/uc_cart.module 2009-04-13 14:34:21 +0000 @@ -459,7 +459,7 @@ } $item_count += $item->qty; - $total += $item->price * $item->qty; + $total += $display_item['#total']; } } @@ -660,12 +660,16 @@ $output = ''; $row_class = 'odd'; + $context = array( + 'location' => 'cart-block-item', + ); + // Loop through each item. foreach ($items as $item) { // Add the basic row with quantity, title, and price. $output .= '' .'' - .''; + .''; // Add a row of description if necessary. if ($item['desc']) { @@ -700,11 +704,15 @@ * @ingroup themeable */ function theme_uc_cart_block_summary($item_count, $item_text, $total, $summary_links) { + $context = array( + 'revision' => 'formatted', + 'location' => 'cart-block-total', + ); // Build the basic table with the number of items in the cart and total. $output = '
'. $item['qty'] .''. $item['title'] .''. uc_currency_format($item['price']) .'
'. uc_price($item['price'], $context) .'
' .'' .''; + .' '. uc_price($total, $context) .''; // If there are products in the cart... if ($item_count > 0) { @@ -875,8 +883,12 @@ '#value' => '', ); } + + $context = array( + 'location' => 'cart-subtotal', + ); $form['items'][$i]['total'] = array( - '#value' => $display_item['#total'], + '#value' => uc_price($display_item['#total'], $context), '#theme' => 'uc_cart_view_price', ); $i++; @@ -992,7 +1004,7 @@ } function theme_uc_cart_view_price($form) { - return uc_currency_format($form['#value']); + return $form['#value']; } function uc_cart_view_table($table) { @@ -1031,9 +1043,14 @@ $table[$i]['total']['#cell_attributes'] = array('nowrap' => 'nowrap', 'class' => 'price'); $table[$i]['#attributes'] = array('valign' => 'top'); } + + $context = array( + 'revision' => 'formatted', + 'location' => 'cart-table-subtotal', + ); $table[] = array( 'total' => array( - '#value' => ''. t('Subtotal:') .' '. uc_currency_format($subtotal), + '#value' => ''. t('Subtotal:') .' '. uc_price($subtotal, $context), '#cell_attributes' => array( 'colspan' => 'full', 'align' => 'right', === modified file 'uc_cart/uc_cart.pages.inc' --- uc_cart/uc_cart.pages.inc 2009-02-27 16:06:16 +0000 +++ uc_cart/uc_cart.pages.inc 2009-04-13 14:34:21 +0000 @@ -191,9 +191,30 @@ } unset($_SESSION['expanded_panes']); + $context = array( + 'revision' => 'altered', + 'location' => 'cart-checkout-item', + ); + $contents = uc_cart_get_contents(); + foreach ($contents as $key => $item) { + $price_info = array( + 'price' => $item->price, + 'qty' => $item->qty, + ); + $context['subject'] = array( + 'cart_item' => $item, + 'node' => node_load($item->nid), + ); + + // Get the altered price per unit, as ordered products have a locked-in + // price. Price altering rules may change over time, but the amount paid + // by the customer does not after the fact. + $contents[$key]->price = uc_price($price_info, $context) / $item->qty; + } + $form['cart_contents'] = array( '#type' => 'hidden', - '#value' => serialize(uc_cart_get_contents()), + '#value' => serialize($contents), ); $form['cancel'] = array( === modified file 'uc_cart/uc_cart_block.css' --- uc_cart/uc_cart_block.css 2009-04-11 23:47:10 +0000 +++ uc_cart/uc_cart_block.css 2009-04-13 14:34:21 +0000 @@ -115,6 +115,10 @@ font-weight: bold; } +.cart-block-summary-total .uc-price { + display: inline; +} + .cart-block-summary-links { text-align: right; } === modified file 'uc_cart/uc_cart_checkout_pane.inc' --- uc_cart/uc_cart_checkout_pane.inc 2008-12-31 13:50:42 +0000 +++ uc_cart/uc_cart_checkout_pane.inc 2009-04-13 14:34:21 +0000 @@ -27,13 +27,26 @@ case 'review': $items = uc_cart_get_contents(); $output = '
'. $item_text .' '. uc_currency_format($total) .'
'; + $context = array( + 'location' => 'cart-review-item', + 'subject' => array(), + ); foreach ($items as $item) { $desc = check_plain($item->title); foreach (module_implements('cart_item_description') as $module) { $desc .= module_invoke($module, 'cart_item_description', $item); } + + $price_info = array( + 'price' => $item->price, + 'qty' => $item->qty, + ); + $context['subject'] = array( + 'cart_item' => $item, + 'node' => node_load($item->nid), + ); $output .= ''; + .''; } $output .= '
'. $item->qty .'x'. $desc - .''. uc_currency_format($item->price * $item->qty) .'
'. uc_price($price_info, $context) .'
'; $review[] = $output; @@ -557,9 +570,23 @@ array('data' => t('Price'), 'class' => 'price'), ); + $context = array( + 'location' => 'cart-checkout-item', + ); + // Set up table rows. foreach (uc_cart_get_contents() as $item) { - $total = ($item->qty) ? $item->qty * $item->price : $item->price; + $price_info = array( + 'price' => $item->price, + 'qty' => $item->qty, + ); + $context['subject'] = array( + 'cart_item' => $item, + 'node' => node_load($item->nid), + ); + $context['revision'] = 'altered'; + + $total = uc_price($price_info, $context); $subtotal += $total; $description = check_plain($item->title); @@ -567,17 +594,24 @@ $description .= module_invoke($module, 'cart_item_description', $item); } + // Remove node from context to prevent the price from being altered. + unset($context['subject']); + $context['revision'] = 'themed'; $rows[] = array( array('data' => t('@qtyx', array('@qty' => $item->qty)), 'class' => 'qty'), array('data' => $description, 'class' => 'products'), - array('data' => check_plain(uc_currency_format($total)), 'class' => 'price'), + array('data' => uc_price($total, $context), 'class' => 'price'), ); } // Add the subtotal as the final row. if ($show_subtotal) { + $context = array( + 'revision' => 'formatted', + 'location' => 'cart-checkout-subtotal', + ); $rows[] = array( - 'data' => array(array('data' => '' . t('Subtotal:') . ' ' . check_plain(uc_currency_format($subtotal)), 'colspan' => 4, 'class' => 'subtotal')), + 'data' => array(array('data' => '' . t('Subtotal:') . ' ' . uc_price($subtotal, $context), 'colspan' => 4, 'class' => 'subtotal')), 'class' => 'subtotal', ); } === modified file 'uc_order/templates/admin.itpl.php' --- uc_order/templates/admin.itpl.php 2009-01-02 16:03:40 +0000 +++ uc_order/templates/admin.itpl.php 2009-04-13 14:34:21 +0000 @@ -15,8 +15,20 @@


- -- qty; ?> x title .' - '. uc_currency_format($product->price * $product->qty); ?>
+ 'order-invoice-admin', +); +foreach ($products as $product) { + $price_info = array( + 'price' => $product->price, + 'qty' => $product->qty, + ); + $context['subject'] = array( + 'order_product' => $product, + ); +?> +- qty; ?> x title .' - '. uc_price($price_info, $context); ?>
  model; ?>
data['attributes']) && count($product->data['attributes']) > 0) {?> data['attributes'] as $key => $value) { === modified file 'uc_order/templates/customer.itpl.php' --- uc_order/templates/customer.itpl.php 2009-04-04 00:03:04 +0000 +++ uc_order/templates/customer.itpl.php 2009-04-13 14:34:21 +0000 @@ -154,7 +154,14 @@ - 'order-invoice-line-item', + 'subject' => array( + 'order' => $order, + ), + ); + foreach ($line_items as $item) { if ($item['line_item_id'] == 'subtotal' || $item['line_item_id'] == 'total') { continue; }?> @@ -164,7 +171,10 @@ : - + @@ -191,13 +201,25 @@ products)) { - foreach ($order->products as $product) { ?> + $context = array( + 'location' => 'order-invoice-product', + 'subject' => array( + 'order' => $order, + ), + ); + foreach ($order->products as $product) { + $price_info = array( + 'price' => $product->price, + 'qty' => $product->qty, + ); + $context['subject']['order_product'] = $product; + ?>
qty; ?> x - title .' - '. uc_currency_format($product->price * $product->qty); ?> + title .' - '. uc_price($price_info, $context, array(), 'formatted'); ?> qty > 1) { echo t('(!price each)', array('!price' => uc_currency_format($product->price))); } ?> === modified file 'uc_order/uc_order.admin.inc' --- uc_order/uc_order.admin.inc 2009-04-01 17:14:08 +0000 +++ uc_order/uc_order.admin.inc 2009-04-13 14:34:21 +0000 @@ -451,6 +451,13 @@ $address = 'billing'; } + $context = array( + 'location' => 'orders-admin', + 'subject' => array( + 'field' => 'order_total', + ), + ); + $result = pager_query($sql, variable_get('uc_order_number_displayed', 30), 0, NULL, $args); while ($order = db_fetch_object($result)) { if ($address == 'shipping') { @@ -470,12 +477,14 @@ $order_name = t('User: !name', array('!name' => $account)); } } + + $context['subject']['order'] = $order; $rows[] = array( 'data' => array( array('data' => uc_order_actions($order, TRUE), 'nowrap' => 'nowrap'), array('data' => $order->order_id), array('data' => check_plain($order_name), 'nowrap' => 'nowrap'), - array('data' => uc_currency_format($order->order_total, TRUE), 'align' => 'right', 'nowrap' => 'true'), + array('data' => uc_price($order->order_total, $context), 'align' => 'right', 'nowrap' => 'true'), array('data' => format_date($order->created, 'custom', variable_get('uc_date_format_default', 'm/d/Y')), 'align' => 'center'), array('data' => $order->title), ), === modified file 'uc_order/uc_order.ca.inc' --- uc_order/uc_order.ca.inc 2009-04-06 16:37:54 +0000 +++ uc_order/uc_order.ca.inc 2009-04-13 14:34:21 +0000 @@ -728,13 +728,13 @@ // Check an user name function uc_order_condition_user_name($order, $settings) { - if ($account = uc_order_user_load($order)) { - return $account->name == $settings['name']; - } - else { + if (empty($order->uid)) { // Anonymous users have no names. return empty($settings['name']); } + else { + return uc_order_user_load($order)->name == $settings['name']; + } } function uc_order_condition_user_name_form($form_state, $settings = array()) { === modified file 'uc_order/uc_order.line_item.inc' --- uc_order/uc_order.line_item.inc 2009-02-27 15:32:25 +0000 +++ uc_order/uc_order.line_item.inc 2009-04-13 14:34:21 +0000 @@ -24,9 +24,21 @@ ); return $lines; case 'cart-preview': + $context = array( + 'revision' => 'altered', + 'location' => 'cart-preview-subtotal-item', + ); $subtotal = 0; foreach ($arg1 as $item) { - $total = ($item->qty) ? $item->qty * $item->price : $item->price; + $price_info = array( + 'price' => $item->price, + 'qty' => ($item->qty) ? $item->qty : 1, + ); + $context['subject'] = array( + 'cart_item' => $item, + 'node' => node_load($item->nid), + ); + $total = uc_price($price_info, $context); $subtotal += $total; } if (module_exists('uc_payment') && variable_get('uc_pane_payment_enabled', TRUE)) { === modified file 'uc_order/uc_order.module' --- uc_order/uc_order.module 2009-04-06 18:31:41 +0000 +++ uc_order/uc_order.module 2009-04-13 14:34:21 +0000 @@ -369,7 +369,15 @@ if (is_array($order->line_items)) { foreach ($order->line_items as $key => $value) { if ($value['type'] == 'subtotal') { - $subtotal = uc_currency_format($order->line_items[$key]['amount']); + $context = array( + 'revision' => 'formatted', + 'location' => 'order-subtotal-token', + 'subject' => array( + 'order' => $order, + 'line_item' => $order->line_items[$key], + ), + ); + $subtotal = uc_price($order->line_items[$key]['amount'], $context); } if ($value['type'] == 'shipping' && is_null($ship_method)) { $ship_method = $value['title']; @@ -377,7 +385,15 @@ } } $values['order-subtotal'] = $subtotal; - $values['order-total'] = uc_currency_format($order->order_total); + $context = array( + 'revision' => 'formatted', + 'location' => 'order-total-token', + 'subject' => array( + 'order' => $order, + 'field' => 'order_total', + ), + ); + $values['order-total'] = uc_price($order->order_total, $context); $values['order-email'] = check_plain($order->primary_email); $values['order-shipping-address'] = uc_order_address($order, 'delivery'); $values['order-shipping-phone'] = check_plain($order->delivery_phone); === modified file 'uc_order/uc_order.order_pane.inc' --- uc_order/uc_order.order_pane.inc 2009-02-05 22:19:50 +0000 +++ uc_order/uc_order.order_pane.inc 2009-04-13 14:34:21 +0000 @@ -331,11 +331,18 @@ } usort($line_items, 'uc_weight_sort'); + $context = array( + 'location' => 'order-line-items', + 'subject' => array( + 'order' => $arg1, + ), + ); $output = ''; foreach ($line_items as $item) { + $context['subject']['line_item'] = $item; $output .= '' .''; + . uc_price($item['amount'], $context) .''; } $output .= '
'. check_plain($item['title']) .':' - . uc_currency_format($item['amount']) .'
'; return $output; @@ -394,6 +401,13 @@ '#collapsed' => FALSE, '#tree' => TRUE, ); + + $context = array( + 'location' => 'order-edit-line-items', + 'subject' => array( + 'order' => $arg1, + ), + ); foreach ($line_items as $item) { $form['line_items'][$item['line_item_id']]['li_id'] = array( '#type' => 'hidden', @@ -425,11 +439,12 @@ ); } else { + $context['subject']['line_item'] = $item; $form['line_items'][$item['line_item_id']]['title'] = array( '#value' => check_plain($item['title']), ); $form['line_items'][$item['line_item_id']]['amount'] = array( - '#value' => uc_currency_format($item['amount']), + '#value' => uc_price($item['amount'], $context), ); } } @@ -659,13 +674,13 @@ if (!is_null($form_state['values']['admin_comment']) && strlen(trim($form_state['values']['admin_comment'])) > 0) { uc_order_comment_save($form_state['values']['order_id'], $user->uid, $form_state['values']['admin_comment']); } - + // Let conditional actions send email if requested. if ($form_state['values']['notify']) { $order = uc_order_load($form_state['values']['order_id']); ca_pull_trigger('uc_order_status_email_update', $order); } - + drupal_set_message(t('Order updated.')); } @@ -724,6 +739,10 @@ 'weight' => 5, ); + $context = array( + 'location' => 'order-view-products', + ); + if (is_array($products)) { foreach ($products as $product) { $data = array(); @@ -745,18 +764,27 @@ '#value' => check_plain($product->model), '#cell_attributes' => array('align' => 'center', 'nowrap' => 'nowrap'), ); + + $context['subject'] = array( + 'order_product' => $product, + ); if (user_access('administer products')) { $data['cost'] = array( - '#value' => uc_currency_format($product->cost), + '#value' => uc_price($product->cost, $context), '#cell_attributes' => array('align' => 'right', 'nowrap' => 'nowrap'), ); } + + $price_info = array( + 'price' => $product->price, + 'qty' => $product->qty, + ); $data['price'] = array( - '#value' => uc_currency_format($product->price), + '#value' => uc_price($product->price, $context), '#cell_attributes' => array('align' => 'right', 'nowrap' => 'nowrap'), ); $data['total'] = array( - '#value' => uc_currency_format($product->qty * $product->price), + '#value' => uc_price($price_info, $context), '#cell_attributes' => array('align' => 'right', 'nowrap' => 'nowrap'), ); $data['#attributes'] = array('valign' => 'top'); @@ -825,6 +853,10 @@ 'weight' => 5, ); + $context = array( + 'location' => 'order-customer-products', + ); + if (is_array($products)) { foreach ($products as $product) { $data = array(); @@ -846,18 +878,27 @@ '#value' => check_plain($product->model), '#cell_attributes' => array('align' => 'center', 'nowrap' => 'nowrap'), ); + + $context['subject'] = array( + 'order_product' => $product, + ); if (user_access('administer products')) { $data['cost'] = array( - '#value' => uc_currency_format($product->cost), + '#value' => uc_price($product->cost, $context), '#cell_attributes' => array('align' => 'right', 'nowrap' => 'nowrap'), ); } + + $price_info = array( + 'price' => $product->price, + 'qty' => $product->qty, + ); $data['price'] = array( - '#value' => uc_currency_format($product->price), + '#value' => uc_price($product->price, $context), '#cell_attributes' => array('align' => 'right', 'nowrap' => 'nowrap'), ); $data['total'] = array( - '#value' => uc_currency_format($product->qty * $product->price), + '#value' => uc_price($price_info, $context), '#cell_attributes' => array('align' => 'right', 'nowrap' => 'nowrap'), ); $data['#attributes'] = array('valign' => 'top'); === modified file 'uc_product/uc_product.css' --- uc_product/uc_product.css 2009-01-07 15:08:16 +0000 +++ uc_product/uc_product.css 2009-04-13 14:34:21 +0000 @@ -9,6 +9,17 @@ margin-left: 4px; } +.uc-price-display { + float: right; + clear: right; + width: 100px; + text-align: center; + font-size: 1.3em; + font-weight: bold; + padding-bottom: 4px; + padding-left: 4px; +} + .display-price { float: right; clear: right; === modified file 'uc_product/uc_product.module' --- uc_product/uc_product.module 2009-04-11 23:08:02 +0000 +++ uc_product/uc_product.module 2009-04-13 14:34:21 +0000 @@ -695,27 +695,47 @@ 'add_to_cart' => 10, )); + $context = array( + 'location' => 'product-view', + 'class' => array( + 'product', + ), + 'subject' => array( + 'node' => $node, + ), + ); + if (module_exists('imagecache') && ($field = variable_get('uc_image_'. $node->type, '')) && isset($node->$field) && file_exists($node->{$field}[0]['filepath'])) { $node->content['image'] = array('#value' => theme('uc_product_image', $node->$field, $teaser, $page), '#access' => $enabled['image'], '#weight' => $weight['image'], ); } - $node->content['display_price'] = array('#value' => theme('uc_product_price', $node->sell_price, 'display-price', TRUE), + + $context['class'][1] = 'display'; + $context['subject']['field'] = 'sell_price'; + $node->content['display_price'] = array('#value' => uc_price($node->sell_price, $context), '#access' => $enabled['display_price'], '#weight' => $weight['display_price'], ); + if (!$teaser) { $node->content['model'] = array('#value' => theme('uc_product_model', $node->model, $teaser, $page), '#access' => $enabled['model'], '#weight' => $weight['model'], ); $node->content['body']['#weight'] = 1; - $node->content['list_price'] = array('#value' => theme('uc_product_price', $node->list_price, 'list-price'), + + $context['class'][1] = 'list'; + $context['subject']['field'] = 'list_price'; + $node->content['list_price'] = array('#value' => uc_price($node->list_price, $context), '#access' => $enabled['list_price'], '#weight' => $weight['list_price'], ); - $node->content['cost'] = array('#value' => theme('uc_product_price', $node->cost, 'cost'), + + $context['class'][1] = 'cost'; + $context['subject']['field'] = 'cost'; + $node->content['cost'] = array('#value' => uc_price($node->cost, $context), '#access' => $enabled['cost'] && user_access('administer products'), '#weight' => $weight['cost'], ); @@ -724,7 +744,9 @@ $node->content['#attributes'] = array('style' => 'display: inline'); } - $node->content['sell_price'] = array('#value' => theme('uc_product_price', $node->sell_price, 'sell-price', $teaser), + $context['class'][1] = 'sell'; + $context['subject']['field'] = 'sell_price'; + $node->content['sell_price'] = array('#value' => uc_price($node->sell_price, $context, array('label' => !$teaser)), '#access' => $enabled['sell_price'], '#weight' => $weight['sell_price'], ); @@ -1076,7 +1098,21 @@ $element['title'] = array( '#value' => node_access('view', $node) ? l($item->title, 'node/'. $node->nid) : check_plain($item->title), ); - $element['#total'] = $item->price * $item->qty; + + $context = array( + 'revision' => 'altered', + 'location' => 'cart-item', + 'subject' => array( + 'cart_item' => $item, + 'node' => $node, + ), + ); + $price_info = array( + 'price' => $item->price, + 'qty' => $item->qty, + ); + + $element['#total'] = uc_price($price_info, $context); $element['data'] = array('#type' => 'hidden', '#value' => serialize($item->data)); $element['qty'] = array( '#type' => 'textfield', @@ -1199,6 +1235,9 @@ '#rows' => array(), ); + $context = array( + 'location' => 'product-tapir-table', + ); foreach ($args as $nid) { $data = array(); $node = node_load($nid); @@ -1217,11 +1256,16 @@ '#value' => l($node->title, 'node/'. $node->nid), '#cell_attributes' => array('width' => '100%'), ); + + $context['subject'] = array('node' => $node); if ($enabled['list_price']) { - $data['list_price'] = array('#value' => uc_currency_format($node->list_price), '#cell_attriubtes' => array('nowrap' => 'nowrap')); + $context['subject']['field'] = 'list_price'; + $data['list_price'] = array('#value' => uc_price($node->list_price, $context), '#cell_attriubtes' => array('nowrap' => 'nowrap')); } if ($enabled['sell_price']) { - $data['price'] = array('#value' => theme('uc_product_price', $node->sell_price, 'sell-price', TRUE), '#cell_attriubtes' => array('nowrap' => 'nowrap')); + $context['subject']['field'] = 'sell_price'; + $context['class'] = array('sell-price'); + $data['price'] = array('#value' => uc_price($node->sell_price, $context, array('label' => FALSE)), '#cell_attriubtes' => array('nowrap' => 'nowrap')); } if (module_exists('uc_cart') && arg(0) != 'admin' && $enabled['add_to_cart']) { === modified file 'uc_store/includes/uc_price.inc' --- uc_store/includes/uc_price.inc 2009-04-12 02:11:38 +0000 +++ uc_store/includes/uc_price.inc 2009-04-13 14:31:10 +0000 @@ -16,19 +16,49 @@ * if it is not already set with the value being the current user object. * @param $options * An associative array containing options that will be passed through to - * any alteration/formatting/theming functions implemented. - * @param $revision - * A string describing the 'revision' of the price to return. Currently - * accepted values are: - * - 'original' => 'The original price', - * - 'altered' => 'Price after passing through the alterer(s)', - * - 'formatted' => 'Price after passing through the formatter', - * - 'themed' => 'Price after passing through the theme layer'. (default) + * any alteration/formatting/theming functions implemented. A list of accepted + * options follows. + * + * 'cache': + * Default: TRUE + * If set FALSE, this price won't be cached. + * + * 'sign': + * Default: variable_get('uc_currency_sign', '$') + * The sign to use when formatting this price. + * + * 'sign_after': + * Default: variable_get('uc_sign_after_amount', FALSE) + * If set to TRUE, the sign will come after the price. + * + * 'prec': + * Default: variable_get('uc_currency_prec', 2) + * Precision to round the price to. + * + * 'dec': + * Default: variable_get('uc_currency_dec', '.') + * Decimal separator. + * + * 'thou': + * Default: variable_get('uc_currency_thou', ',') + * Thousand separator. + * + * 'label': + * Default: TRUE + * If set to TRUE, the + * + * 'revision': + * Default: 'themed' + * A string describing the revision of the price to return. Currently + * accepted values are: + * - 'original' => 'The original price', + * - 'altered' => 'Price after passing through the alterer(s)', + * - 'formatted' => 'Price after passing through the formatter', + * - 'themed' => 'Price after passing through the theme layer'. (default) * * This function handles price alteration, formatting, theming, and caching. - * */ -function uc_price($price_info, $context, $options = array(), $revision = NULL) { +function uc_price($price_info, $context, $options = array()) { global $user; $values = array(); @@ -40,13 +70,17 @@ ); } - // Initialize the options array. + // Initialize the options and context. $options += array( 'cache' => variable_get('uc_price_caching', TRUE), ); + $context += array( + 'revision' => 'themed' + ); + // Clamp to allowed revisions. - switch ($revision) { + switch ($context['revision']) { case 'original': case 'altered': case 'formatted': @@ -54,7 +88,7 @@ break; default: - $revision = 'themed'; + $context['revision'] = 'themed'; } // Get all the active handlers. @@ -114,7 +148,7 @@ } // Return the requested revision. - return $values[$revision]; + return $values[$context['revision']]; } /** === modified file 'uc_store/uc_store.css' --- uc_store/uc_store.css 2009-02-19 15:55:26 +0000 +++ uc_store/uc_store.css 2009-04-13 14:32:10 +0000 @@ -1,5 +1,9 @@ /* $Id$ */ +.uc-price { + white-space: nowrap; +} + .uc-store-admin-table { margin: 1em auto; border: 1px dashed #bbb; === modified file 'uc_store/uc_store.module' --- uc_store/uc_store.module 2009-04-12 02:11:38 +0000 +++ uc_store/uc_store.module 2009-04-13 14:32:10 +0000 @@ -568,7 +568,7 @@ } $context['class'][] = 'uc-price'; // Class the element. - $output = '
'; + $output = ''; // Prefix(es). if ($options['label'] && isset($options['prefixes'])) { $output .= implode('', $options['prefixes']); @@ -579,7 +579,7 @@ if ($options['label'] && isset($options['suffixes'])) { $output .= implode('', $options['suffixes']); } - $output .= '
'; + $output .= ''; return $output; } # Begin bundle IyBCYXphYXIgcmV2aXNpb24gYnVuZGxlIHY0CiMKQlpoOTFBWSZTWR/p4ucAJuf/gH/XVVR///// /6/eCr////pgLb7vLzN895y3j214Ho971n32u75u+w+X3zus+c7c+vX33o+J8u3AG33egD5u4Apo ruwBQO7uBtgbYBXQ758kXTetA3HngdzuRUC0PB7Pe53aG5g6AevXTTpvu6gPvNc2g+kVburmm9Zy elUuEkhDRMmBNMgCBoKYU8KGPUgeoGIAAAMQJImgCBCCaKek9EyIMjQAaabUMgAABoABpiEEk0NK n6ap5qnlD1NqBiekNAGgAAAAAGgJNJEmiCCaTaUafqj9UbUMaeoQ2iHo1A9T1BhGDQR6JhBEoiaa AJowEmamJplPQNI0p7U1PBIepo9QAAyDRoJEggJpoCUn40JtCNT0JpNPUP1T0IDQ0eoADQHlDTnR B9RFEH+B7yEA9ZJDxLShT2eVCtD3Qb9ir9ft363NJ1k+tbqpeFXGrIOrwFj58DkT7ZR8tbCkr++0 MfLczdK4FBU99A4drugaZsVn1t7xbxmQxFKgijW7wrrpdkkVThkgwT/Tl07Fz62ejE0+3tGOhoe+ LFCe7BwWPylaNWA72Dk4DD2kUeVHg7uTlOXR5MmZhmGAZMMkm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