This question has been flagged
2 Replies
9503 Views

We are using product_images_olbs module to add images from local repository in openERP 6.1. But in openERP 7.0, the function to choose a picture with your windows explorer seems to work, but as soon as you save the image is not uploaded. The binary field that holds the image looks like this:

'file':fields.function(_get_image, fnct_inv = _set_image, type = "binary", filters = '*.png,*.jpg,*.gif')

It specifies a function 'fnct_inv' to save the field to the database, which in turn calls _set_image, however neither of these functions are called.

Can you please help me on this issue?

Avatar
Discard
Author Best Answer

I have fixed this by using the version 7 module branch below:

https://code.launchpad.net/~camptocamp/openerp-product-attributes/7.0-product_images-migr/+merge/145630

Avatar
Discard

Not an Answer. Please see What should I avoid in my questions?. I might want to replace this with a comment on the answer or editing your question.

Yes, as per Daniels comment, please update your original question with this new information.

I think you'll hit a lot of problems trying to get this module working with an unsupported version - according to the links I posted, the module supports up to 6.1. Your best option now would be to get in contact with the author - maybe give them a link to this Question. Otherwise, I feel like it won't be worth your time trying to debug this (rather complex) module yourself..

Sorry I can't be of more help but I don't have the time - perhaps somebody else can pick up on this (the module author?)?

Also try following this questin: http://help.openerp.com/question/379/what-changed-in-fieldsbinary-and-widget-image-from-61-to-7/ - it is about changes between 6.1 and 7 in terms of binary fields, and somebody wanting to update your module - you may find what you need

Author

Thanks for your reply Max. I have fixed this by using below reference. https://code.launchpad.net/~camptocamp/openerp-product-attributes/7.0-product_images-migr/+merge/145630...Its Working fine :-)

Great, glad its solved :) I have edited your original question and your answer to this question to organise the information so it makes more sense for future readers. Can you accept it as the solution?

Author

sure.I'm accepting this :-) One more query is in product add-on product.product object have column like image, image_small and image_medium. In product_images_olbs add-on, I'm inherit this object and need to store binary values in image, image_small and image_medium column by calling resize image function like 'image_medium':fields.function(_get_image_medium, type = "binary", string = "Medium-sized image"),....While adding this columns in inherited object, I cant save image. Can you help on this?

you should ask a new question for this new issue

Author

Ok :-) I'm accepting this....Its resolved

To accept an answer as the solution you have to click the Tick image to the left of the answer

I have tried the way of 10054.It's useful

Best Answer

This looks like a bug with the product_images_olbs module. Since this module is not an official OpenERP module, bug reports should be sent to the author here. This Q&A forum is more a place for functional and specific technical questions than bug reports (See posting guidelines).

Also, by the looks of it, the module only supports version 6.1 and below.

If you could give us some more details about the issue, for example a specific line of code that you think is causing the problem, we might be able to help you. Otherwise, please get in contact with the author and I am sure they will be glad to help.

Avatar
Discard