Force onBeforeProductUpdate() with mass action

  • Posts: 634
  • Thank you received: 16
9 years 8 months ago #193836

-- HikaShop version -- : 2.3.5
-- Joomla version -- : 2.5

I created a plugin that triggers when onBeforeProductUpdate(&$element,&$do)

and I want to apply it massively to my 500 products without having to open them all and saving them+

I tried with mass actions by changing the value of a dummy field but looks like the changes are applied to the field without executing a whole update process.

How can I force the execution in mass actions of an update as it was made from the user?

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

  • Posts: 13201
  • Thank you received: 2322
9 years 8 months ago #193865

Hi,

When using the "Before a product is updated" trigger in the mass actions, it will affect only the product which will be updated, no the other ones.

So to update whole product values, it will require to execute a mass action manually.

Else, in your plugin, you have to execute a MySQL query in order to update all the products when one is updated.

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

Time to create page: 0.071 seconds
Powered by Kunena Forum