Author Topic: Products ordering in Category view  (Read 304 times)

Genius WebDesign

  • 3rd party VirtueMart Developer
  • Jr. Member
  • *
  • Posts: 175
    • Genius WebDesign
Products ordering in Category view
« on: October 06, 2017, 11:36:26 am »

On my clients VM shop we need to apply a specific ordering of products in all categories.

My client wants this particular ordering:  ordering ASC, id DESC

So basically we want to order products by ordering 0 to ∞ as primary ordering and then id DESC as secondary ordering.
How can I do this without hacking the core?


Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 3247
  • Joomla & Virtuemart addon developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3.0.x.y
Re: Products ordering in Category view
« Reply #1 on: October 12, 2017, 13:50:23 pm »
I think the only solution is to use ordering desc, in this case id desc should be the secondary ordering because it's the primary key.
Core have no secondary choice, if you really need, you have to add it in the core(hacking it or doing a system plugin to override the class)