[SOLVED] Filter products by badge

  • Posts: 117
  • Thank you received: 6
6 years 5 months ago #282549

-- HikaShop version -- : 3.2.1
-- Joomla version -- : 3.8.2
-- PHP version -- : 7.1.0
-- Browser(s) name and version -- : Firefox 57.0

Hi!

Tell me, please, how can I filter the products with a certain badge? For example, some products have a badge New, I need a link to get a list of categories / products to which this badge is assigned. How do I get this link (for menu or for other purposes)? I found earlier on the forum some kind of lifehack on this topic, but I can not find it anymore.


Sorry for my English, it's not my native language.
Last edit: 6 years 4 months ago by alin. Reason: SOLVED added

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

  • Posts: 81481
  • Thank you received: 13062
  • MODERATOR
6 years 5 months ago #282562

Hi,

It's not possible to filter products by badge.
A hack might be able to do that, or a custom plugin implementing the onBeforeProductListingLoad trigger:
www.hikashop.com/support/documentation/6...reProductListingLoad

Alternatively, create a specific unpublished category for the badge and assign it to the products you want to have that badge. Then, you can easily fitler the products based on that category.

The following user(s) said Thank You: alin

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

  • Posts: 117
  • Thank you received: 6
6 years 5 months ago #282631

It's hard for me to make a custom plugin... I thought may be Business version can do it with for example Mass Actions - I've looked at the demo but it doesn't allow to create them. Is it possible for example to add a new (created) product to a specific unpublished category for the badge and at the same time to assign a specific badge to that product with Mass Actions?


Sorry for my English, it's not my native language.

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

  • Posts: 81481
  • Thank you received: 13062
  • MODERATOR
6 years 5 months ago #282659

Hi,

Badges can't be added by mass actions or used in filters of mass actions. So that's not possible.

The following user(s) said Thank You: alin

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

  • Posts: 117
  • Thank you received: 6
6 years 4 months ago #283187

There is a good answer : https://www.hikashop.com/forum/product-category-display/862936-display-new-badge-for-number-of-days.html#128642 . It turns out that this function requires a commercial version.


Sorry for my English, it's not my native language.

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

Time to create page: 0.060 seconds
Powered by Kunena Forum