Jump to content

1.6.0.9 how make to add sort by reference in list of products?


Recommended Posts

  • 4 years later...

Hi, i write in this old topic my solution for prestashop 1.7.2:

in /modules/ps_facetedsearch/src/Ps_FacetedsearchProductSearchProvider.php

Search for:

Quote

    private function getAvailableSortOrders()
    {
        return [

and after add:

Quote

(new SortOrder('product', 'reference', 'asc'))->setLabel(
                $this->module->getTranslator()->trans('Reference', array(), 'Modules.Facetedsearch.Shop')
            ),
 

Work for me! I hope is useful for someone..

Edited by Idroclic (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...