Follow link for example. This is a huge problem right now and we are on a live site. Before upgrading to RC6 the attributes were displaying total prices correctly. I looked at the attribute price settings and they are correct in the settings and the MySQL DB. As you can see everything is $0.00 in this product (and all other products with variations).
Look at this block of code in attribute.module in _uc_attribute_alter_form():
case 'total':
$context['type'] = 'product';
$context['subject']['node'] = $product;
$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 && $attribute->display != 3) {
break;
}
$option->price returns the proper amounts with print_r(); 50, 100, 250 and so on...
$display_price returns 0 with print_r().
I tried rolling back to UC RC4 and 5, but no love. The base price of these products are 0, but the drop downs should be showing 0 + the option price total.
Comments
Comment #1
Island Usurper commentedI believe you need the latest version of uc_discount. The last time I saw that happen, Ubercart had changed the way uc_price() worked, and I hadn't changed the way uc_discount used it.
If you're not using uc_discount, I'm not sure what's going on.
Comment #2
robomalo commentedThank you! I can't believe that was it. I spent over 2 hours looking at each line in the attribute module over and over.