Changing product "Ordering" on the backend by catagory

  • Posts: 41
  • Thank you received: 4
3 years 5 months ago #333635

-- HikaShop version -- : 4.4.2
-- Joomla version -- : 3.9.27

Hi

I have been categorizing the store on our website and have realized that all of the products are just in the order they were added to the store.

It's probably simple, but I've been searching for a while and are unable to find a way to re-ordering products on the back end without using the ordering buttons or typing all the numbers myself manually.

I would like to be able to do it alphabetically for some categories and then others I'd like to re order them using the product codes. I've checked in mass actions and couldn't see it there. I would like to do it on a per category basis, but I would accept being able to do the whole store at once.

Any help would be amazing,

Cheers

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 5 months ago #333640

Hi,

In the settings page of each menu items of the type HikaShop products listing or categories listing (you can access that via the Joomla menu manager), you have a tab "products options". Under that tab, you have a setting "ordering column" and a setting "ordering direction". If you set the ordering column to "product_name" and the ordering direction to ascendant, then the products listed in that menu item will be sorted alphabetically based on the name of the products on the pages of that menu item.
So if you have several menu items for different categories, you can configure the ordering differently in them thanks to these settings in each menu item.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 4
3 years 4 months ago #333922

Hi!
I'm sorry for the lateness of my reply, I've been on holiday for the past week.

I know about these options in the menu manager however I would like to order the items in the backend anyway as I would find that a lot more useful for other purposes.

Is there no way to reorder the products easily in the hikashop products menu (other than using the ordering buttons on the right or having to type in all the order numbers manually and pressing the update button) as they are just ordered in the order they were input into the store, which isn't particularly useful.

Sorry for the confusion. It will help in my frontend store if i can do it this way, as I will be able to make exception easily using the order changing buttons on the fly.

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 4 months ago #333923

Hi,

On the backend products listing, you can click on the title of each column so that the listing will be ordered based on that column's data.
So if you click on the "Name" title, the products will be ordered based on their product name. In fact, this is the same in any listing of the backend where the title can be clicked.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 4
3 years 4 months ago #334010

I knew about this type of reordering was hoping of a way to re order that would change the order number permanently to keep them in this order.


As you can see the numbers on the right still reflect their 'true order'

I would like to keep the menu ordering field as "Ordering" still as I am using the grouped by category sub element filter and it seems to not function as well when switching the product ordering to alphabetically by name. It will break all of the category sub sections into smaller categories in order to ensure the whole store is still alphabetical.


For example in this image above, we have more than 3 metallic threads, the others are just positioned further down the list as to preserver the alphabetical ordering.

If I could re-order the ordering in the backend easier than doing on a per product basis, I could have much more granular control over the ordering of the store as a whole.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 4 months ago #334021

Hi,

In your menu item settings, under the "products options" tab, you have the settings "ordering column" and "ordering direction" which define how the products are ordered on the whole listing. This is done when loading the data from the database directly in MySQL.

Then, you set the "sub element filter" to "group by category". This can't be done when loading the data from the database and is done after that.

So if you base the ordering of the products on something which is global to all the products regardless of the category, you would get a strange result on the frontend since you'll have products from the same category on different pages of the listing.

The best you can do right now is to create a custom field of the table "product" and enter the value you want in each for each product and then base the ordering of the menu item on it. That way, you can really have the order you want.
But it's a bit tedious to do, especially if you have a lot of products.
Thinking about it, I think I found a way to automatically sort the products taking into account first the categories and then the normal ordering of the products in their respective categories. I've made a patch for it.
You can replace the file components/com_hikashop/views/product/view.html.php with the one in the zip attached and it will add the patch.

File Attachment:

File Name: view.html_...6-30.zip
File Size:25 KB

Attachments:
Last edit: 3 years 4 months ago by nicolas.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 4
3 years 4 months ago #334057

Hey!

Yeah, as you stated at the top, that is what I have been experiencing! You managed to put it much more eloquently than I could.

I've installed that patch that you've created and I have only found one issue with it, as it appears to work perfectly at first impression.
However, it will work as long as all the products can fit onto one page.

Eg.


This is the first page of results (which would have had a messed up order prior to the patch.) and it looks fine at first glance.


However when you look at the second page of results there are more headed pins on it.


If I increase the number of results per page.


The ordering is fixed and they get added to the right category again.

Here is a link to the page I'm showing: www.sewingmachinesuk.uk/haberdashery/category/66-pins

Sorry for bringing up more issues! I really really appreciate the effort that has gone into this patch! Really amazing.

Cheers

Attachments:
Last edit: 3 years 4 months ago by jasmine247. Reason: Add a link to the page I'm talking about

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
3 years 4 months ago #334063

Hi,

Well, if the category of products is the cut-off category for the pagination, it's normal that you got some products of it on the first page and some in the second page.
And looking into it, it does seem that the 3 products of that category in the second page are the last ones of that category.
Now, in that case, that would mean that the "ordering" of the categories is not filled in properly under the Products>Categories listing. Could you check there ?
What I see there would mean that the ordering configured under the "categories options" tab of your menu item results in an order of the categories different from the "ordering" you set in the Products>Categories.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 4
3 years 4 months ago #334159

Hi,

"Now, in that case, that would mean that the "ordering" of the categories is not filled in properly under the Products>Categories listing. Could you check there ?"
By this a presume you're talking about in the menu items?

I have set the category options now to category_ordering and am getting even stranger results.

In the main listing now I am getting even more fragmentation,

sewingmachinesuk.co.uk/haberdashery

As you can see on that link, I am getting the same scissors showing up twice on the same page. They shouldn't even be the top category as that category comes much further down the ordering in the backend.

Please Log in or Create an account to join the conversation.

  • Posts: 12953
  • Thank you received: 1778
3 years 4 months ago #334180

Hello,

On the back-end, could you check and configure the ordering of your product categories via "Hikashop->Products->Categories" ? Thank you.

Kind regards,
Mohamed.

Please Log in or Create an account to join the conversation.

  • Posts: 41
  • Thank you received: 4
3 years 4 months ago #334284

Hi,

I don't know if I'm just not understanding but, what exactly am I checking/configuring in this products screen?

This is the screen you're talking about, right?



Cheers

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 4747
  • Thank you received: 644
  • MODERATOR
3 years 4 months ago #334360

Hello,

Yes, Mohamed means to use the ordering in order to define the sort order of your categories, like shown in your screenshot.
In details, you have to use your order button (red bordered in my screenshot), to define the order sort of your categories relative to each other.



Hope this will help you to progress on your subject.
Regards

Last edit: 3 years 4 months ago by Philip.

Please Log in or Create an account to join the conversation.

Time to create page: 0.122 seconds
Powered by Kunena Forum