Mass action configuration

  • Posts: 1119
  • Thank you received: 114
5 years 5 months ago #300417

Hi,

I am looking for help in mass action configuration.

1. We want to put products to discount category based on product price and select products only who were created more then 3 months ago...

So as example if product price is lower or equal to 10 euros then it should go into category "discount -15%" and if it's more then 3 months old.
But it still effects products who were created like only 1 month ago. Is there something wrong with screenshot attached?




Thanks

Attachments:

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

  • Posts: 81540
  • Thank you received: 13069
  • MODERATOR
5 years 5 months ago #300418

Hi,

You're using > for the product_created filter. So this means that it will keep only the products with a product_created bigger than {time} - 7884000, so created after that date, which is the opposite of what you want.
You should use instead <

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

  • Posts: 1119
  • Thank you received: 114
5 years 5 months ago #300516

Hi,

Thanks for help.

Another question.
We also would like to filter by product name which contains word "Jeans" and word "Bridges". Basically we need to select products with those names only. How should we deal with that?

Can we add multiply words in contains and seperate it with comma or we should create filter for each word?

Thanks

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

  • Posts: 1119
  • Thank you received: 114
5 years 5 months ago #300527

Another question.

How can we add category to products who are in 2 different categories?

So if we have 2 categories with names "Dresses" and "Shoes". We need select product from only this categories and add category with name "Sale".

Should we create mass action for each category or this somehow can be added into one?
If we do like in the screenshot bellow, we get error "1052 Column 'product_id' in where clause is ambiguous".



Attachments:

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

  • Posts: 81540
  • Thank you received: 13069
  • MODERATOR
5 years 5 months ago #300518

Hi,

There is no good solution for that.
You could use the operator "LIKE" and write %Jeans%
However, it will not match if there is not at least one character before and one after the word Jeans in the name.
And for several words, you could use %Jeans%Bridges% but this means that both words need to be in the name and in that same order and with characters before and after.
To have something more useful, it requires complex MySQL queries or PHP processing, like there is in the HikaShop products search plugin for example. And that's not possible with the options offered in mass actions.
Also, there is no OR logic with the mass action filters, only AND. So if you create two filters, both need to match for the product to be selected. I'm afraid you're touching the limits of what mass actions can do here.

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

  • Posts: 1119
  • Thank you received: 114
5 years 5 months ago #300589

Hi,

Thanks for explanation. So it seems we will have to create mass action for each category. How many mass actions system can handle?

Thanks

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

  • Posts: 26007
  • Thank you received: 4004
  • MODERATOR
5 years 5 months ago #300590

Hello,

Best would be to have a "IN" element but unfortunately, it would require a very complicated development to integrate it in the current mass action system.
Regarding the "LIKE", it will perform a mysql LIKE action, so the limitation is more related to your mysql/server than just HkaShop.

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.083 seconds
Powered by Kunena Forum