Checkmo.php 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\OfflinePayments\Model;
  7. /**
  8. * Class Checkmo
  9. *
  10. * @method \Magento\Quote\Api\Data\PaymentMethodExtensionInterface getExtensionAttributes()
  11. *
  12. * @api
  13. * @since 100.0.2
  14. */
  15. class Checkmo extends \Magento\Payment\Model\Method\AbstractMethod
  16. {
  17. const PAYMENT_METHOD_CHECKMO_CODE = 'checkmo';
  18. /**
  19. * Payment method code
  20. *
  21. * @var string
  22. */
  23. protected $_code = self::PAYMENT_METHOD_CHECKMO_CODE;
  24. /**
  25. * @var string
  26. */
  27. protected $_formBlockType = \Magento\OfflinePayments\Block\Form\Checkmo::class;
  28. /**
  29. * @var string
  30. */
  31. protected $_infoBlockType = \Magento\OfflinePayments\Block\Info\Checkmo::class;
  32. /**
  33. * Availability option
  34. *
  35. * @var bool
  36. */
  37. protected $_isOffline = true;
  38. /**
  39. * @return string
  40. */
  41. public function getPayableTo()
  42. {
  43. return $this->getConfigData('payable_to');
  44. }
  45. /**
  46. * @return string
  47. */
  48. public function getMailingAddress()
  49. {
  50. return $this->getConfigData('mailing_address');
  51. }
  52. }