Мне кажется что формирование цены происходить в этом файле:
components/com_virtuemart/views/cart/tmpl/default_pricelist.php
За общую сумму заказа отвечает параметр COM_VIRTUEMART_CART_TOTAL
Вот урывок кода с default_pricelist.php:
<fieldset class="vm-fieldset-pricelist">
<table class="cart-summary"
cellspacing="0"
cellpadding="0"
border="0"
width="100%">
<tr>
<th class="vm-cart-item-name" >< ?php echo vmText::_ ('COM_VIRTUEMART_CART_NAME') ?></th>
<th class="vm-cart-item-sku" >< ?php echo vmText::_ ('COM_VIRTUEMART_CART_SKU') ?></th>
<th class="vm-cart-item-basicprice" >< ?php echo vmText::_ ('COM_VIRTUEMART_CART_PRICE') ?></th>
<th class="vm-cart-item-quantity" >< ?php echo vmText::_ ('COM_VIRTUEMART_CART_QUANTITY') ?></th>
< ?php if (VmConfig::get ('show_tax')) {
$tax = vmText::_ ('COM_VIRTUEMART_CART_SUBTOTAL_TAX_AMOUNT');
if(!empty($this->cart->cartData['VatTax'])){
if(count($this->cart->cartData['VatTax']) < 2) {
reset($this->cart->cartData['VatTax']);
$taxd = current($this->cart->cartData['VatTax']);
$tax = shopFunctionsF::getTaxNameWithValue($taxd['calc_name'],$taxd['calc_value']);
}
}
?>
<th class="vm-cart-item-tax" >< ?php echo "<span class='priceColor2'>" . $tax . '' ?></th>
< ?php } ?>
<th class="vm-cart-item-discount" >< ?php echo "<span class='priceColor2'>" . vmText::_ ('COM_VIRTUEMART_CART_SUBTOTAL_DISCOUNT_AMOUNT') . '' ?></th>
<th class="vm-cart-item-total" >< ?php echo vmText::_ ('COM_VIRTUEMART_CART_TOTAL') ?></th> <<<<<<<<<<<<<<<<<<<<ТУТ
</tr>
Как достать число из параметра COM_VIRTUEMART_CART_TOTALP который отвечает за общую сумму заказа. И вставить в параметр
<input name="amount" value="0" type="hidden">
Вместо "0" вставить COM_VIRTUEMART_CART_TOTAL
Путь к файлу: public_html/components/com_virtuemart/views/cart/tmpl/order_done.php
Вот урывок кода с default_pricelist.php:
echo '<div class="vm-wrap vm-order-done">';
if (vRequest::getBool('display_title',true)) {
echo '<h3>'.vmText::_('COM_VIRTUEMART_CART_ORDERDONE_THANK_YOU').'</h3>';
echo '<form method="POST" accept-charset="utf-8" action="https://www.liqpay.com/api/pay">
<input name="public_key" value="XXX" type="hidden">
<input name="amount" value="0" type="hidden"> <<<<<<<<<<<<<<<<<<<<ТУТ
<input name="currency" value="RUB" type="hidden">
<input name="description" value="Мой товар" type="hidden">
<input name="type" value="donate" type="hidden">
<input name="pay_way" value="card,delayed" type="hidden">
<input name="language" value="ru" type="hidden">
<input src="//static.liqpay.com/buttons/p7ru.radius.png" mce_src="http://static.liqpay.com/buttons/p7ru.radius.png" name="btn_text" type="image"> </form><form method="POST" accept-charset="utf-8" action="https://www.liqpay.com/api/pay"><br></form><form method="POST" accept-charset="utf-8" action="https://www.liqpay.com/api/pay"><b mce_style="line-height: 1.3em;" style="line-height: 1.3em>';
}
$this->html = vRequest::get('html', vmText::_('COM_VIRTUEMART_ORDER_PROCESSED') );
echo $this->html;
if (vRequest::getBool('display_loginform',false)) {
$cuser = JFactory::getUser();
if (!$cuser->guest) echo shopFunctionsF::getLoginForm();
}
echo '</div>';