質問

Is there any way to display an error message after actionProductUpdate hook is executed in a module?

Looking at the Prestashop code, the hook is triggered in AdminProductController, but the return value is not being processed. Also adding any message in passed Product object seems to be out of my requirement.

The purpose is to provide user with an error message in case of wrong input, database update error etc after clicking on Save button in back-office product edit page.

役に立ちましたか?

解決

in belvg blog user Prestarocket post the the very helpful comment:

"Why not using hookActionProductSave ? With this hook, you can add errors to the controller ($this->context->controller->errors[])"

Regards

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top