Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function disablePayments($observer) {
- $quote = $observer->getEvent()->getQuote();
- $paymentInstance = $observer->getEvent()->getMethodInstance();
- if ($quote) {
- $country = $quote->getShippingAddress()->getCountry();
- if ($country == 'India') {
- if (!$methodInstance instanceof PayTm_Method_Instance) {
- $observer->getEvent()->getResult()->isAvailable = false;
- }
- }
- }
- }
Add Comment
Please, Sign In to add comment