DKM84 Posted March 4, 2012 Share Posted March 4, 2012 Hi, I have a lot of items in my shop and if possible I would like them to be sorted by quantity and out-of-stock in stock items first. then the 0 in stock but still available for ordering and last the 0 in stock and unavailable for ordering. I have set PS_PRODUCTS_ORDER_BY to 6 in phpmyadmin I am gonna remove the dropdown menu on the front-end, so manual sorting is no longer possible. I now have al items that are in stock on top, but after that it's a mess I tried editing classes/product.php -> getAllProducts ORDER BY '.(isset($orderByPrefix) ? pSQL($orderByPrefix).'.' : '').'`'.pSQL($orderBy).'` '.pSQL($orderWay).' LIMIT '.intval($pageNumber * $nbProducts).', '.intval($nbProducts)); But I have been unsuccesfull, anybody got some advice on this? //add prestashop 1.3.1 Link to comment Share on other sites More sharing options...
outlet.ee Posted September 1, 2012 Share Posted September 1, 2012 Hello, did you get anywhere with this? I need almost same thing: in stock first, then newest. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now