You need to sign in to do that
Don't have an account?

Product after update trigger and Product Activation
Hi
I'm really lost on this one.
I have an After Update trigger on Product, when I hit the activate/deactivate action link on a product in the Products search result list the checkbox is updated correctly BUT the trigger is not fired.
For testing purposes I implemented a button to do the same and when I use it to activate/deactivate it works fine.
Any suggestion why this happens and how to solve it and get the triggered fired when I use the action link?
Much appreciated
I've confirmed this behavior. It's calling the standard edit controller ( /{!Product2.Id}/e?act=0&retURL... ) that does not have the usual save=x parameter (where x is any value, but usually the word Save). It seems to bypass all validation, workflow, and trigger logic. Nothing shows up in the debug logs at all. I suspect that this is a bug, and you should report it to Technical Support.
All Answers
I've confirmed this behavior. It's calling the standard edit controller ( /{!Product2.Id}/e?act=0&retURL... ) that does not have the usual save=x parameter (where x is any value, but usually the word Save). It seems to bypass all validation, workflow, and trigger logic. Nothing shows up in the debug logs at all. I suspect that this is a bug, and you should report it to Technical Support.
Thanks a lot :-)
Do you have any idea if this action link can be removed?
I don't want ambiguous behavior in my app
You can't remove it, as it is a standard link. However, if you override the product2.edit action with a Visualforce component, you can perform the update in your custom code, which fires your trigger correctly. This is only a shortterm solution, as it introduces a CSRF attack, but is no worse than the original problem, which is also CSRF vulernerable. Alternatively, have the edit page offer them a chance to cancel or confirm the action so you yourself prevent the CSRF attack.
Is this issue fixed already? Or do we still need to change our product2.edit page ?