Shareable.php 639 B

1234567891011121314151617181920212223242526
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Downloadable\Model\Source;
  7. use Magento\Downloadable\Model\Link;
  8. /**
  9. * Shareable source class
  10. */
  11. class Shareable implements \Magento\Framework\Data\OptionSourceInterface
  12. {
  13. /**
  14. * {@inheritdoc}
  15. */
  16. public function toOptionArray()
  17. {
  18. return [
  19. ['value' => Link::LINK_SHAREABLE_YES, 'label' => __('Yes')],
  20. ['value' => Link::LINK_SHAREABLE_NO, 'label' => __('No')],
  21. ['value' => Link::LINK_SHAREABLE_CONFIG, 'label' => __('Use config')]
  22. ];
  23. }
  24. }