- Posts: 299
- Thank you received: 2
Ordering products after brand
11 years 5 months ago #199466
by LAMF
Ordering products after brand was created by LAMF
-- url of the page with the problem -- :
www.bil-filtertjanst.se
-- HikaShop version -- : 2.4.0
-- Joomla version -- : 3.4.1
-- PHP version -- : 5.4.39
-- Browser(s) name and version -- : No browser issue
Hi,
On my new website I am using a customized module to filter Brands + models + build year in order to get the correct products displayed. This filter is working fine but how can I order the Brands in the first filter box the way I want them?
It looks like this now: www.awesomescreenshot.com/image/117639/e...5677cfeee84efb073825
In backend I have it sorted like this in the Products => Brands.
www.awesomescreenshot.com/image/117660/2...288d33426174c901efd3
So my question is why doesn't frontend display it that way also?
Best regards
Micke
-- HikaShop version -- : 2.4.0
-- Joomla version -- : 3.4.1
-- PHP version -- : 5.4.39
-- Browser(s) name and version -- : No browser issue
Hi,
On my new website I am using a customized module to filter Brands + models + build year in order to get the correct products displayed. This filter is working fine but how can I order the Brands in the first filter box the way I want them?
It looks like this now: www.awesomescreenshot.com/image/117639/e...5677cfeee84efb073825
In backend I have it sorted like this in the Products => Brands.
www.awesomescreenshot.com/image/117660/2...288d33426174c901efd3
So my question is why doesn't frontend display it that way also?
Best regards
Micke
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
11 years 5 months ago #199481
by Mohamed Thelji
Replied by Mohamed Thelji on topic Ordering products after brand
Hello Micke,
A solution can be to directly use the "Order" option through your back-end brand listing page.how can I order the Brands in the first filter box the way I want them?
I didn't totally understood your question, do you want your front-end filter do display like the default back-end filter of the product listing page ("Hikashop->Products") ?So my question is why doesn't frontend display it that way also?
Please Log in or Create an account to join the conversation.
11 years 5 months ago #199611
by LAMF
Replied by LAMF on topic Ordering products after brand
Hi Mohamed,
In the first screen shot there is the listing as it is now in the front end for a customer who visits the web shop.
That order is not correct, the order we want is like the second screen shot that is taken from the backend config of the Products => Brands.
I have used the Direct sub elements option from the drop-down to make this ordering.
But this won't have any effect on the displaying in the front end.
In the first screen shot there is the listing as it is now in the front end for a customer who visits the web shop.
That order is not correct, the order we want is like the second screen shot that is taken from the backend config of the Products => Brands.
I have used the Direct sub elements option from the drop-down to make this ordering.
But this won't have any effect on the displaying in the front end.
Please Log in or Create an account to join the conversation.
11 years 5 months ago #199698
by nicolas
Replied by nicolas on topic Ordering products after brand
Hi,
I'm not able to look at the page of your screenshot on your website. Could you provide an access/link to it ?
If you use a standard HikaShop brand filter, the brands have to be ordered in the way you ordered them in the backend because the code the code is done, I don't see how it would not be the case.
Now if you have a custom module and don't use the standard filters of HikaShop, it means that there is an "order by" missing in the query loading the brands in that selector and you should see with the developer of the module to add that. It should be really simple.
I'm not able to look at the page of your screenshot on your website. Could you provide an access/link to it ?
If you use a standard HikaShop brand filter, the brands have to be ordered in the way you ordered them in the backend because the code the code is done, I don't see how it would not be the case.
Now if you have a custom module and don't use the standard filters of HikaShop, it means that there is an "order by" missing in the query loading the brands in that selector and you should see with the developer of the module to add that. It should be really simple.
Please Log in or Create an account to join the conversation.
11 years 5 months ago #199736
by LAMF
Replied by LAMF on topic Ordering products after brand
Hi,
I see what you mean so then the custom module is not totally ok.
Problem is that the developer I used won't do anyting to help me so I guess I have to set my hope on you guys that you one day will adopt this module. Otherwise I will have to live with it as it is.
I see what you mean so then the custom module is not totally ok.
Problem is that the developer I used won't do anyting to help me so I guess I have to set my hope on you guys that you one day will adopt this module. Otherwise I will have to live with it as it is.
Please Log in or Create an account to join the conversation.
11 years 5 months ago #199779
by nicolas
Replied by nicolas on topic Ordering products after brand
Hi,
I didn't understood that your were the same person that sent us a filter module. I had a quick look.
Change the line:
to:
in the helper.php file of the module and that will do the ordering on the brands.
I didn't understood that your were the same person that sent us a filter module. I had a quick look.
Change the line:
Code:
$query->clear()->select('`category_name`')->from('#__hikashop_category')->where('`category_id`='.$query->quote($jform['filter_0']));
Code:
$query->clear()->select('`category_name`')->from('#__hikashop_category')->where('`category_id`='.$query->quote($jform['filter_0']))->order('category_ordering ASC');
The following user(s) said Thank You: LAMF
Please Log in or Create an account to join the conversation.
11 years 5 months ago #199948
by LAMF
Replied by LAMF on topic Ordering products after brand
Hi Nicolas,
Yes it's me
I have made the changes to the helper.php file and it sort of helped but strangely not all of them....
See this screenshot: docs.google.com/file/d/0B1796ZOMWxCJdnk1...VU/edit?usp=drivesdk
I have in backend set the Brands ordering up like this and it all looks just fine:
docs.google.com/file/d/0B1796ZOMWxCJUzkz...kE/edit?usp=drivesdk
So what can be wrong with the ordering?
Best regards,
Micke
Yes it's me
I have made the changes to the helper.php file and it sort of helped but strangely not all of them....
See this screenshot: docs.google.com/file/d/0B1796ZOMWxCJdnk1...VU/edit?usp=drivesdk
I have in backend set the Brands ordering up like this and it all looks just fine:
docs.google.com/file/d/0B1796ZOMWxCJUzkz...kE/edit?usp=drivesdk
So what can be wrong with the ordering?
Best regards,
Micke
Please Log in or Create an account to join the conversation.
11 years 5 months ago #200026
by nicolas
Replied by nicolas on topic Ordering products after brand
Hi,
Try to also change the line:
to:
Otherwise, I'm afraid it would require proper testing and glancing at your email it looks complex to set that all up to try and reproduce the problem.
Providing support on a custom module we didn't work on is obviously outside what this forum is about.
Try to also change the line:
Code:
$query->clear() ->select('category_id AS value, category_name AS text') ->from('#__hikashop_category') ->where('category_parent_id IN ('.$filter_value.')') ;
Code:
$query->clear() ->select('category_id AS value, category_name AS text') ->from('#__hikashop_category') ->where('category_parent_id IN ('.$filter_value.')') ->order('category_ordering ASC');
Providing support on a custom module we didn't work on is obviously outside what this forum is about.
Please Log in or Create an account to join the conversation.
11 years 5 months ago #200039
by LAMF
Replied by LAMF on topic Ordering products after brand
Hi,
Thanks it helped almost...
It orders all of them but two.. So I guess those two must be some kind of weird.
Anyway thanks for helping with this custom made module even though it is out of the standard box.
Best regards
Micke
Thanks it helped almost...
It orders all of them but two.. So I guess those two must be some kind of weird.
Anyway thanks for helping with this custom made module even though it is out of the standard box.
Best regards
Micke
Please Log in or Create an account to join the conversation.
Time to create page: 0.217 seconds