Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Builder: Cleanup ir.attachment after deleting images (image, image-attachment etc) #15

Open
bobslee opened this issue May 10, 2017 · 0 comments

Comments

@bobslee
Copy link
Contributor

bobslee commented May 10, 2017

Images which afterward will be removed from the Builder Form, should be deleted from "ir.attachment" afterwards.

This prevents polution and orphanes in the "ir.attachment" table.

Current analysis:

  1. Regarding Orbeon, there's no (HTTP)-request - to the Odoo persistence service - which handles the deletion of these images.
  2. There's solely the (HTTP)-request /crud/orbeon/.../data.xml - Which for which images either exist or not in the data as URL-path.

A possible approach would be, to determine and delete the "ir.attachment" (images) for the Builder Form which don't exist in the (XML) data by URL mentoined above in bulletpoint 2.

It would also be a good idea to store the Orbeon control-/fieldname for the image on the "ir.attachment" model as well. Which could be implemented in the function handle_binary_data()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant