VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: ermes on November 29, 2019, 12:59:31 PM

Title: Sorting products in multiple categories
Post by: ermes on November 29, 2019, 12:59:31 PM
Hi forum, this is an old question but without answers: how can i manually sort products that are in more than one category?
I suppose that it isn't possible to do because sorting process is based on porderding record (in #__virtuemart_products table) that is unique for all categories. There is an extension that can do it?
In the future versions it's possible to add a teble (es: #__virtuemart_product_ordering with virtuemart_product_id/virtuemart_category_id/pordering columns) and use it for sorting products in multiple category?
I hope in yours reply!
Title: Re: Sorting products in multiple categories
Post by: ermes on November 29, 2019, 16:41:32 PM
Searching into forum i can see that the "sorting" is a taboo topic  :D
Title: Re: Sorting products in multiple categories
Post by: AH on November 29, 2019, 19:11:58 PM
It is not taboo

Product "ordering" is configured by category with all products showing in that category.

People generally do not want to force a product to be in a fixed position across all the categories in which it may be displayed as ordering tends to reflect the items in each category.

Therefore such a feature is not supported natively.

Title: Re: Sorting products in multiple categories
Post by: Studio 42 on November 29, 2019, 20:32:41 PM
It's not right.
category>products Ordering is the field 'ordering' from #__virtuemart_product_categories
So it should not be a problem to assign ordering for each category.
My component VmBePro (in last releases) have a tree view, so you can manage and move the category>products and change the ordering(automatically or manually) using ajax
Note :pordering is for parent>child products ordering
Title: Re: Sorting products in multiple categories
Post by: AH on November 30, 2019, 10:40:00 AM
Thought that is what I said

Ordering for a product is by product/product_category

Assigning an order for different categories at product level seems odd, when you do not know the relative or content of products for each category to which the product belongs

Or have I misunderstood this whole thing?


Title: Re: Sorting products in multiple categories
Post by: Studio 42 on December 01, 2019, 12:43:15 PM
Quote from: AH on November 30, 2019, 10:40:00 AM

Or have I misunderstood this whole thing?
No, It was to clarify that "pordering" and "ordering" is not the same thing(for ermes) and 2 differents tables in the DB.
Title: Re: Sorting products in multiple categories
Post by: ermes on December 02, 2019, 11:05:11 AM
Thank you for yours replies. I have see after that there is the table. But another question: how can I sort the products by category in root level view? I have to assign the canonical category to the products?
Title: Re: Sorting products in multiple categories
Post by: Milbo on December 03, 2019, 17:38:14 PM
In the root level view, category 0? Interesting point.
Title: Re: Sorting products in multiple categories
Post by: ermes on December 19, 2019, 18:08:48 PM
Isn't possible, right?
Title: Re: Sorting products in multiple categories
Post by: pinochico on December 19, 2019, 22:12:01 PM
I don't see any bussines benefit for eshop and customers, why it should be.
You can explain more why you require such a function?

I have not seen anywhere in the eshop (for example Amazon) that I would like to see products differently sorted by price, brand, name or date (news), stock, action.
Title: Re: Sorting products in multiple categories
Post by: Studio 42 on December 19, 2019, 23:41:13 PM
ermes us a main category and set this as the shop entry.