Document.php 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. /**
  3. * Mageplaza
  4. *
  5. * NOTICE OF LICENSE
  6. *
  7. * This source file is subject to the Mageplaza.com license that is
  8. * available through the world-wide-web at this URL:
  9. * https://www.mageplaza.com/LICENSE.txt
  10. *
  11. * DISCLAIMER
  12. *
  13. * Do not edit or add to this file if you wish to upgrade this extension to newer
  14. * version in the future.
  15. *
  16. * @category Mageplaza
  17. * @package Mageplaza_LayeredNavigation
  18. * @copyright Copyright (c) Mageplaza (https://www.mageplaza.com/)
  19. * @license https://www.mageplaza.com/LICENSE.txt
  20. */
  21. namespace Mageplaza\LayeredNavigation\Api\Search;
  22. use Magento\Framework\Api\Search\Document as SourceDocument;
  23. /**
  24. * Class Document
  25. * @package Mageplaza\LayeredNavigation\Api\Search
  26. */
  27. class Document extends SourceDocument
  28. {
  29. /**
  30. * Get Document field
  31. *
  32. * @param string $fieldName
  33. * @return \Magento\Framework\Api\AttributeInterface
  34. */
  35. public function getField($fieldName)
  36. {
  37. return $this->getCustomAttribute($fieldName);
  38. }
  39. }