sayaarief Posted February 1, 2016 Share Posted February 1, 2016 (edited) Hi all, I'm currently using prestashop webservice with python. I would like to update my prestashop product default image through webservice. I have managed to upload the new image, i'm not sure how to change the current default image using webservice. lets say my new image id = 66 my code: template_data['product'].update({'id_default_image':66}) the code is succesful updated to template_data, but whenever it goes to python prestashop lib, the value is revert back to original value. Is it possible? Any helps? Thanks in advance. Edited February 10, 2016 by sayaarief (see edit history) Link to comment Share on other sites More sharing options...
realirocco Posted August 23, 2016 Share Posted August 23, 2016 I've same problem... I'm working with Java and when I update a product via prestashop api all work fine except the id default image... I think this is a readonly value. I tried to upload image with put method but it returns an error... Can anyone help me... Link to comment Share on other sites More sharing options...
carolinalour Posted September 5, 2016 Share Posted September 5, 2016 Hi, did you manage to make this work? Thanks!! Link to comment Share on other sites More sharing options...
realirocco Posted September 6, 2016 Share Posted September 6, 2016 Finally i found a solution. I found out when you delete default image by webservice no image are set as default. if the product hasn't a default picture the first image uploaded became the default image. So i delete the default image, I upload the new one, than if necessary i upload the old default image... it's very expensive so if someone has an alternative solution it would be great! Sorry for my english i hope you can understand... Link to comment Share on other sites More sharing options...
carolinalour Posted September 6, 2016 Share Posted September 6, 2016 Hi, Sorry, I'm not sure I understand. So what you're saying is that you have to delete ALL images associated to a product before uploading any new ones? could you please provide a coded example? Thanks Link to comment Share on other sites More sharing options...
realirocco Posted September 7, 2016 Share Posted September 7, 2016 I delete just the main image so, when I upload a new image, this became the new main image. Link to comment Share on other sites More sharing options...
carolinalour Posted September 7, 2016 Share Posted September 7, 2016 Indeed thank you! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now