Download.php 1005 B

12345678910111213141516171819202122232425262728293031323334353637
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. /**
  7. * Backup grid item renderer
  8. *
  9. * @author Magento Core Team <core@magentocommerce.com>
  10. */
  11. namespace Magento\Backup\Block\Adminhtml\Grid\Column\Renderer;
  12. class Download extends \Magento\Backend\Block\Widget\Grid\Column\Renderer\Text
  13. {
  14. /**
  15. * Renders grid column
  16. *
  17. * @param \Magento\Framework\DataObject $row
  18. * @return mixed
  19. */
  20. public function _getValue(\Magento\Framework\DataObject $row)
  21. {
  22. $url7zip = __(
  23. 'The archive can be uncompressed with <a href="%1">%2</a> on Windows systems.',
  24. 'http://www.7-zip.org/',
  25. '7-Zip'
  26. );
  27. return '<a href="' . $this->getUrl(
  28. '*/*/download',
  29. ['time' => $row->getData('time'), 'type' => $row->getData('type')]
  30. ) . '">' . $row->getData(
  31. 'extension'
  32. ) . '</a> &nbsp; <small>(' . $url7zip . ')</small>';
  33. }
  34. }