Hello,
I need to be able to "not show" payment options if the total cart amount is above a set limit. I am looking at the payment.tpl and founded the area I need to modify. My question is total amount variable accessible in this template and if so what data structure is it in?
Scott
I need to do this aswell so this is what I have done to acheive it.
You need to edit the appropriate file in ..\catalog\model\payment
The files all seem to follow the same formatting so should work for any of them
You need to add these lines:
This will prevent the payment method from showing if the sub total is greater than £100.
You need to edit the appropriate file in ..\catalog\model\payment
The files all seem to follow the same formatting so should work for any of them
You need to add these lines:
Directly above:if ($this->cart->getSubTotal() > '100')
$status = FALSE;
$method_data = array();
if ($status) {
$method_data = array(
'id' => 'cod',
'title' => $this->language->get('text_title'),
'sort_order' => $this->config->get('cod_sort_order')
);
}
return $method_data;
}
}
?>
This will prevent the payment method from showing if the sub total is greater than £100.
-
VIEW ALL EXTENSIONS * EXTENSION SUPPORT * WEBSITE * CUSTOM REQUESTS
Who is online
Users browsing this forum: No registered users and 19 guests