/** * validates data of the payment form on server side * */ public function validate() { parent::validate(); $session = Mage::getSingleton('core/session'); if (Mage::getStoreConfig('payment/sofort_ideal/ask_holder')) { if (!$session->getIdealHolder()) { Mage::throwException(Mage::helper('pnsofortueberweisung')->__('Please fill out the account holder')); } if (!$session->getIdealAccountNumber()) { Mage::throwException(Mage::helper('pnsofortueberweisung')->__('Please fill out the account number')); } } if (!$session->getIdealBankCode()) { Mage::throwException(Mage::helper('pnsofortueberweisung')->__('Please fill out the bank code')); } return $this; }
public function validate() { parent::validate(); $session = Mage::getSingleton('core/session'); if (!$session->getLsHolder()) { Mage::throwException(Mage::helper('pnsofortueberweisung')->__('Please fill out the account holder')); } if (!$session->getLsAccountNumber()) { Mage::throwException(Mage::helper('pnsofortueberweisung')->__('Please fill out the account number')); } if (!$session->getLsBankCode()) { Mage::throwException(Mage::helper('pnsofortueberweisung')->__('Please fill out the bank code')); } return $this; }