Logo.php 832 B

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Paypal\Model\System\Config\Source;
  7. /**
  8. * Source model for available logo types
  9. */
  10. class Logo implements \Magento\Framework\Option\ArrayInterface
  11. {
  12. /**
  13. * @var \Magento\Paypal\Model\ConfigFactory
  14. */
  15. protected $_configFactory;
  16. /**
  17. * @param \Magento\Paypal\Model\ConfigFactory $configFactory
  18. */
  19. public function __construct(\Magento\Paypal\Model\ConfigFactory $configFactory)
  20. {
  21. $this->_configFactory = $configFactory;
  22. }
  23. /**
  24. * {@inheritdoc}
  25. */
  26. public function toOptionArray()
  27. {
  28. $result = ['' => __('No Logo')];
  29. $result += $this->_configFactory->create()->getAdditionalOptionsLogoTypes();
  30. return $result;
  31. }
  32. }