Skip to content

Commit

Permalink
MAGETWO-87342: #12860: Sort by Product Name doesn't work with Ancor a…
Browse files Browse the repository at this point in the history
…nd available filters. #1192
  • Loading branch information
Oleksii Korshenko authored Feb 1, 2018
2 parents 7787945 + f08b36f commit fe09530
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -366,15 +366,21 @@ protected function _renderFiltersBefore()
'search_result.'. TemporaryStorage::FIELD_SCORE . ' ' . $this->relevanceOrderDirection
);
}
return parent::_renderFiltersBefore();
}

/**
* @inheritdoc
*/
protected function _beforeLoad()
{
/*
* This order is required to force search results be the same
* for the same requests and products with the same relevance
* NOTE: this does not replace existing orders but ADDs one more
*/
$this->setOrder('entity_id');

return parent::_renderFiltersBefore();
return parent::_beforeLoad();
}

/**
Expand Down

0 comments on commit fe09530

Please sign in to comment.