diff --git a/app/code/local/LesMills/YandexCheckout/Method.php b/app/code/local/LesMills/YandexCheckout/Method.php new file mode 100644 index 0000000..66f74df --- /dev/null +++ b/app/code/local/LesMills/YandexCheckout/Method.php @@ -0,0 +1,142 @@ +getCode()}/$k", $s ?: $this->_storeId + );} + + /** + * 2019-10-29 + * @override + * @see Mage_Payment_Model_Method_Abstract::getInfoInstance() + * @used-by Mage_Payment_Block_Form::getInfoData() + * @return Info|QP + */ + function getInfoInstance() {return $this->_ii;} + + /** + * 2019-10-29 + * @override + * @see Mage_Payment_Model_Method_Abstract::getTitle() + * @used-by app/design/frontend/base/default/template/checkout/onepage/payment/methods.phtml + * @return string + */ + function getTitle() {return 'Яндекс.Касса';} + + /** + * 2019-10-29 + * @override + * @see Mage_Payment_Model_Method_Abstract::isApplicableToQuote() + * @used-by Mage_Payment_Block_Form_Container::_canUseMethod() + * @used-by Mage_Payment_Block_Form_Container::getMethods() + * @param Q $q + * @param int|null $checksBitMask + * @return bool + */ + function isApplicableToQuote($q, $checksBitMask) {return true;} + + /** + * 2019-10-29 + * @override + * @see Mage_Payment_Model_Method_Abstract::isAvailable() + * @used-by Mage_Payment_Helper_Data::getStoreMethods() + * @param Q|null $q [optional] + * @return bool + */ + function isAvailable($q = null) {return (bool)(int)$this->getConfigData('active', $q ? $q->getStoreId() : null);} + + /** + * 2019-10-29 + * @override + * The @see Mage_Payment_Model_Method_Abstract class does not have the `setInfoInstance` method: + * it is handled by @see Varien_Object. + * @see Varien_Object::__call() + * @used-by Mage_Payment_Block_Form_Container::_assignMethod() + * @used-by Mage_Payment_Model_Info::getMethodInstance() + * @param Info|QP $v + */ + function setInfoInstance(Info $v) {$this->_ii = $v;} + + /** + * 2019-10-29 + * @override + * The @see Mage_Payment_Model_Method_Abstract class does not have the `setSortOrder` method: + * it is handled by @see Varien_Object. + * @see Varien_Object::__call() + * @used-by Mage_Payment_Helper_Data::getStoreMethods() + * @param int $v + */ + function setSortOrder($v) {$this->sort_order = $v;} + + /** + * 2019-10-29 + * @override + * The @see Mage_Payment_Model_Method_Abstract class does not have the `setStore` method: + * it is handled by @see Varien_Object. + * @see Varien_Object::__call() + * @param string|null $v «34» + * @used-by Mage_Payment_Helper_Data::getStoreMethods() + */ + function setStore($v) {$this->_storeId = (int)$v;} + + /** + * 2019-10-29 + * @used-by setSortOrder() + * @used-by Mage_Payment_Helper_Data::_sortMethods() + * @var int + */ + public $sort_order; + + /** + * 2019-10-29 + * @used-by getInfoInstance() + * @used-by setInfoInstance() + * @var Info|QP + */ + private $_ii; + + /** + * 2019-10-29 + * @used-by getConfigData() + * @used-by setStore() + * @var int + */ + private $_storeId; +} \ No newline at end of file diff --git a/app/code/local/LesMills/YandexCheckout/etc/config.xml b/app/code/local/LesMills/YandexCheckout/etc/config.xml index 32e99b4..dbb8c49 100644 --- a/app/code/local/LesMills/YandexCheckout/etc/config.xml +++ b/app/code/local/LesMills/YandexCheckout/etc/config.xml @@ -3,15 +3,15 @@ Dmitry Fedyuk - 0.0.1 + 0.0.2 - + 0 - LesMills_YandexCheckout_Payment - + LesMills_YandexCheckout_Method + diff --git a/app/code/local/LesMills/YandexCheckout/etc/system.xml b/app/code/local/LesMills/YandexCheckout/etc/system.xml index 191c264..6b492ae 100644 --- a/app/code/local/LesMills/YandexCheckout/etc/system.xml +++ b/app/code/local/LesMills/YandexCheckout/etc/system.xml @@ -3,7 +3,7 @@ - + text 1 @@ -21,7 +21,7 @@ adminhtml/system_config_source_yesno - +