AdditionalFieldsProviderInterface.php 701 B

12345678910111213141516171819202122232425
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\AdvancedSearch\Model\Adapter\DataMapper;
  7. /**
  8. * Provide additional fields for data mapper during search indexer
  9. * Must return array with the following format: [[product id] => [field name1 => value1, ...], ...]
  10. * @api
  11. * @since 100.2.0
  12. */
  13. interface AdditionalFieldsProviderInterface
  14. {
  15. /**
  16. * Get additional fields for data mapper during search indexer based on product ids and store id.
  17. *
  18. * @param array $productIds
  19. * @param int $storeId
  20. * @return array
  21. * @since 100.2.0
  22. */
  23. public function getFields(array $productIds, $storeId);
  24. }