No results on filtering

  • Posts: 36
  • Thank you received: 0
10 years 2 months ago #172431

-- HikaShop version -- : 2.3.1
-- Joomla version -- : 3.2.3
-- Browser(s) name and version -- : chrome

I created multiple costum fields and a filter on frontend, but if I choose any of them, no results where found. I search around the forum, but didn't found the solution. I also don't get any error messages.

What am I doing wrong?

Attachments:

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 2 months ago #172442

Hi,

Your website is currently offline ; so we can't take a look.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

  • Posts: 36
  • Thank you received: 0
10 years 2 months ago #172458

Jerome wrote: Hi,

Your website is currently offline ; so we can't take a look.

Regards,


The site is in private/developement. I need to create you an account if you want to take a look on it. With admin too?

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 2 months ago #172497

Hi,

Admin can be useful if you want us to apply a patch or fix your configuration.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

  • Posts: 36
  • Thank you received: 0
10 years 2 months ago #172565

I've send you a PM with the userdata, thank you!

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

  • Posts: 13201
  • Thank you received: 2322
10 years 2 months ago #172656

Hi,

How are you displaying the filters ? In the category listing or via the filter module ?
If it is the module, in the "menu" parameter, you have to set the id of a product listing menu which is listing all the available products on your website.

Else are you sure that the entered data are valid ?

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

  • Posts: 36
  • Thank you received: 0
10 years 1 month ago #173507

I display it in the category listing.

What you define as valid? I didn't found anywhere rules for validation.

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 1 month ago #173936

Hi,

I think that Xavier was talking about the credentials.
The url we got ask for a username/password and the user/password we have from you, are not working.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

  • Posts: 36
  • Thank you received: 0
10 years 1 month ago #173968

I changed from maintenance mode to htaccess and tested the login data I've send you and it works for me to login in both. htaccess and website.

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

  • Posts: 12953
  • Thank you received: 1778
10 years 1 month ago #174089

Hello,
Your issue is coming from the fact that you have added all of your products through the "Rosen" category, and that you don't have any product through the sub-categories of the "Rosen" category.
The solution will just be to add your product through the "Rosen" sub-categories.

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

  • Posts: 36
  • Thank you received: 0
10 years 1 month ago #174133

No I don't have all products in the Rosen category. Some subcategories are empty, but all plant products are in sub categories of the Rosen category. For example product category / Rosen / Historische Rosen

If you use in the backend the filter "Direct subelements" in the product view of "Rosen" category, the list is empty. So all products are in the subcategories.

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

  • Posts: 82864
  • Thank you received: 13372
  • MODERATOR
10 years 1 month ago #174179

As far as I can see, the problem is likely due to a bug.
Could you replace the content of the file administrator/components/com_hikashop/classes/filter.php with this pastebin.com/K2zMf5cW and try again ?
If that still doesn't help, please provide either a super admin account so that we can access your joomla configuration in order to turn on the "debug mode" option for our tests, or turn that option on yourself so that we can see the debug data at the bottom of the pages.

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

  • Posts: 36
  • Thank you received: 0
10 years 1 month ago #174251

I changed the code and turned the debug mode on.

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

  • Posts: 36
  • Thank you received: 0
10 years 1 month ago #174257

I found the issue. You check for if $field=' ' to determine if you want to search for it or not. This results in this query.

SELECT DISTINCT b.* 
  FROM #__hikashop_product_category AS a 
  LEFT JOIN #__hikashop_product AS b 
  ON a.product_id=b.product_id 
  WHERE b.product_published=1 
  AND b.product_type = 'main' 
  AND a.category_id IN (20) 
  AND (b.product_access = 'all' OR b.product_access LIKE '%,1,%') 
  AND (b.untergruppe LIKE '%none%') 
  AND (b.farbgruppe LIKE '%none%') 
  AND (b.bluetenmerkmale LIKE '%none%') 
  AND (b.duft LIKE '%none%') 
  AND (b.einmalmehrmalsbluehend LIKE '%none%') 
  AND (b.gesundheit LIKE '%none%') 
  AND (b.winterhaerte LIKE '%none%') 
  AND (b.hoehe LIKE '%none%') 
  AND (b.besondereeignung LIKE '%Schnittblume%') 
  AND (b.wuchsform LIKE '%none%') 
  AND (b.stammrosenverfuegbarkeit LIKE '%none%') 
  AND (b.pflanzabstand LIKE '%none%') 
  ORDER BY a.ordering ASC 
  LIMIT 0, 21

If I add a
&& $field!='none')
then the query looks like
SELECT DISTINCT b.* 
  FROM #__hikashop_product_category AS a 
  LEFT JOIN #__hikashop_product AS b 
  ON a.product_id=b.product_id 
  WHERE b.product_published=1 
  AND b.product_type = 'main' 
  AND a.category_id IN (20) 
  AND (b.product_access = 'all' OR b.product_access LIKE '%,1,%') 
  AND (b.besondereeignung LIKE '%Schnittblume%') 
  ORDER BY a.ordering ASC 
  LIMIT 0, 21

Which works ...


In complete
foreach($infoGet as $field){
    if($field!=$filter->filter_namekey && $field!=' ' && $field!='none'){
	//$fieldsList.=' b.'.$filter->filter_options['custom_field'].' =  '.$database->Quote($field).' OR';
	$fieldsList[]='b.'.$filter->filter_options['custom_field'].' LIKE \'%'.hikashop_getEscaped($field,true).'%\'';
    }
}

Last edit: 10 years 1 month ago by svanschu.

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

  • Posts: 36
  • Thank you received: 0
10 years 1 month ago #175181

No further response?

Will this be fixed or am I wrong?

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 1 month ago #175183

Hi,

Nicolas and I have submit several fixes for the filters during the last weeks.
These modifications will be integrated in the next HikaShop release.
Your "none" problem is known and we are still investigating on it (because there are a lot of code in the class field that we have to test).

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

Time to create page: 0.099 seconds
Powered by Kunena Forum