Virtuemart: Gastos de envio gratuitos para más de una cantidad solamente para España
WebHuesca :: Fecha de creación: ago 16, 2011Credits: This is a tweak of the code pasted by #nickdwhite to the Virtuemart forums almost 4 years ago. Thanks Nick!
1.) Abre el archivo de clases: administrator/components/com_virtuemart/classes/ps_checkout.php
2.) Encuentra el código:
3.) Cambialo por el siguiente código:
$q = “SELECT country from #__{vm}_user_info WHERE user_info_id = ‘” . $vars["ship_to_info_id"] . “‘”;
$db->query($q);
if( $vendor_freeshipping > 0 && $vars['order_subtotal_withtax'] >= $vendor_freeshipping && $db->f(“country”) == “ESP”) {
4.) Reemplaza (ESP) por el pais que desees que tenga los gastos gratuitos a partir de ese pedido
5.) Specify the free shipping limit by clicking on Edit Store in the Virtuemart control panel (you will find it in the Store Information section of the page).
6.) Especifica la “Mínima cantidad para envío gratuito” (o de lo contrario no será capaz de completar el checkout)
Nota: Necesitas crear una tarifa de envio con todos los paises, excluyendo ESPAÑA claro, con todos los pesos.
Hope this helps someone!!! ![]()

