Please see this : I post this on VIrtumart forum but i want to ask here too :
http://forum.virtuemart.net/index.php?topic=107598.0
http://forum.virtuemart.net/index.php?topic=107598.0
<?php
public function createPriceDiv($name,$description,$product_price,$priceOnly=false,$switchSequel=false,$quantity = 1.0){
// vmdebug('createPriceDiv '.$name,$product_price[$name]);
if(empty($product_price)) return '';
?>
<?php
if(empty($product_price)) return '';
?>
<?php
if(empty($product_price)) return '0.00';
?>
<?php
if (VmConfig::get('coupons_enable')) {
?>
<?php
if(!empty($this->layoutName) && $this->layoutName=='default') {
// echo JHTML::_('link', JRoute::_('index.php?view=cart&task=edit_coupon',$this->useXHTML,$this->useSSL), JText::_('COM_VIRTUEMART_CART_EDIT_COUPON'));
echo $this->loadTemplate('coupon');
}
?>
<?php
if (!empty($this->cart->cartData['couponCode'])) {
?>
<?php
echo $this->cart->cartData['couponCode'] ;
echo $this->cart->cartData['couponDescr'] ? (' (' . $this->cart->cartData['couponDescr'] . ')' ): '';
?>
<?php
echo $this->currencyDisplay->createPriceDiv('couponTax','', $this->cart->pricesUnformatted['couponTax'],false);
?>
<?php
}
?>
<?php
echo $this->currencyDisplay->createPriceDiv('salesPriceCoupon','', $this->cart->pricesUnformatted['salesPriceCoupon'],false);
?>
<?php
echo $this->currencyDisplay->createPriceDiv('salesPriceCoupon','', $this->cart->pricesUnformatted['salesPriceCoupon'],false);
?>
<?php
echo (-1*$this->currencyDisplay->createPriceDiv('salesPriceCoupon','', $this->cart->pricesUnformatted['salesPriceCoupon'],false));
?>
<?php
echo $this->currencyDisplay->createPriceDiv('salesPriceCoupon','', $this->cart->pricesUnformatted['salesPriceCoupon']* -1,false);
?>
<?php
return $this->redirecter('index.php?option=com_virtuemart&view=cart&task=edit_coupon' , $redirectMsg);
?>
<?php
//return $this->redirecter('index.php?option=com_virtuemart&view=cart&task=edit_coupon' , $redirectMsg);
?>