Jump to content

PS1.7 hookActionProductUpdate gets multiple called and no image uploaded


Recommended Posts

Hi,

 

I am still adapting my modules to 1.7 and seeing now problems in the backoffice tabs.

 

Now I have the issue that the working 1.6 version with adaptions to 1.7 now displays at the

hookDisplayAdminProductsExtra at the Products, but did not submit images and pdf files.

Also if I dump the $_FILES, it is a empty array.

 

So i checked the form upload and added debug output in the "hookActionProductUpdate".

 

There I noticed that it got called 8 times instead of only once after pressing the save button.

 

Does anyone know why this occurs?

 

I wanted to update the DB and Upload a FIle at the hookActionProductUpdate, the select field got submitted but the previous workin files are not submitted. Was there a change in 1.7 ?

 

Has anyone a working example of file upload at the hookDisplayAdminProductsExtra ?

 

Many Thanks in advance

Edited by BluTiGeS (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

I'm also trying to save extra product field displayed through hookDisplayAdminProductsExtra on 1.7, but the save ajax call retrns "This form should not contain extra fields", becuse I just loaded a tpl with a checkbox named form[modulename][value] as shown here, while I suppose I should use the prestashop methods to render the form. How did you add a file input field correctly to the module option section of the product?

 

Thanks.

Edited by frankit (see edit history)
Link to comment
Share on other sites

  • 3 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...