News:

Looking for documentation? Take a look on our wiki

Main Menu

Prices & totals disappeared in cart with 2.0.4

Started by DaggaTora, April 16, 2012, 11:35:24 AM

Previous topic - Next topic

bpluijms

Oke, I figured it out.

After updating to VM 2.0.6 all TAX-rules (BTW) are not attached to the product. So I had to add them all one by one again.
That's why the tax didn't show up in the cart.

Is there a way to default add a tax-rule to ALL products (instead of all one by one)?

greyliar

Ok, I found a solution and it's pretty simple.
First of all, you must update VirtueMart files in your template if you are using overrides (cart directory, file: default_pricelist.php). You must do this, because update modifies all price layouts in the cart. Open original file and compare with file in your template directory, then add the changes.

Second step, you must go to configuration in VirtueMart component, to the "Prices" tab and mark all prices to show.

That's all, everything shows and works.

Milbo

Quote from: bpluijms on April 23, 2012, 11:31:31 AM
Is there a way to default add a tax-rule to ALL products (instead of all one by one)?

What you are asking for is in fact the default.   :-? Use apply generic discounts and you see the effecting discounts listed below the dropdown menue.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

DaggaTora

Ok! That works!

But I still have a problem in cart. I have 2 columns: Price and Total. "Product A" cost 30€ and if I set quantity to 4 I need to show 30€ under Price column and 120€ under Total, but I always get 120€, in both columns.

I'm using:

<?php
if (VmConfig::get('checkout_show_origprice',1) && !empty($this->cart->pricesUnformatted[$pkey]['basePriceWithTax']) && $this->cart->pricesUnformatted[$pkey]['basePriceWithTax'] != $this->cart->pricesUnformatted[$pkey]['salesPrice'] ) {
echo '<span class="line-through">'.$this->currencyDisplay->createPriceDiv('basePriceWithTax',''$this->cart->pricesUnformatted[$pkey],true,false,$prow->quantity) .'</span><br />' ;
}
echo $this->currencyDisplay->createPriceDiv('salesPrice',''$this->cart->pricesUnformatted[$pkey],false,false,$prow->quantity?>


Does anybody knows how to show just the price of the product in cart (those 30€)?
Joomla 2.5.17 | VM2.0.26d | PHP 5.3.28

DaggaTora

Quote from: DaggaTora on April 24, 2012, 18:46:46 PM
Ok! That works!

But I still have a problem in cart. I have 2 columns: Price and Total. "Product A" cost 30€ and if I set quantity to 4 I need to show 30€ under Price column and 120€ under Total, but I always get 120€, in both columns.

I'm using:

<?php
if (VmConfig::get('checkout_show_origprice',1) && !empty($this->cart->pricesUnformatted[$pkey]['basePriceWithTax']) && $this->cart->pricesUnformatted[$pkey]['basePriceWithTax'] != $this->cart->pricesUnformatted[$pkey]['salesPrice'] ) {
echo '<span class="line-through">'.$this->currencyDisplay->createPriceDiv('basePriceWithTax',''$this->cart->pricesUnformatted[$pkey],true,false,$prow->quantity) .'</span><br />' ;
}
echo $this->currencyDisplay->createPriceDiv('salesPrice',''$this->cart->pricesUnformatted[$pkey],false,false,$prow->quantity?>


Does anybody knows how to show just the price of the product in cart (those 30€)?

No idea on how to set price for 1 product?
Joomla 2.5.17 | VM2.0.26d | PHP 5.3.28

DaggaTora

Joomla 2.5.17 | VM2.0.26d | PHP 5.3.28

Milbo


this->currencyDisplay->createPriceDiv('salesPrice','', $this->cart->pricesUnformatted[$pkey],false,false,$prow->quantity)


The last parameter is the quantity, just set for the desired line a 1 instead of $prow->quantity
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

cas

I just upgraded from 2.0.1.k that worked great to 2.0.6 and now in the cart the Price, Tax, Discount, Total are all blank.  I do not have any template overrides.  Is there a fix? 

DaggaTora

Quote from: Milbo on April 27, 2012, 16:50:08 PM

this->currencyDisplay->createPriceDiv('salesPrice','', $this->cart->pricesUnformatted[$pkey],false,false,$prow->quantity)


The last parameter is the quantity, just set for the desired line a 1 instead of $prow->quantity

Great! Thanx Milbo!
Joomla 2.5.17 | VM2.0.26d | PHP 5.3.28