Commit Graph

8 Commits (c0436db6c6d0db0f60b6645ce8fea068e3e7395a)

Author SHA1 Message Date
Florian da Costa 4f42cf895d [IMP] Allow to delete attachment without res_model
But allow it only if a file pattern is set, to avoid deleting all orphan attachments are some are auto-generated by Odoo
2023-12-28 16:39:40 +01:00
Florian da Costa 5693420182 [MIG] autovacuum_message_attachment : migrate to v16 2023-11-28 12:27:14 +01:00
Akim Juillerat 1e19a4b6dd Add selection of attachments through inheriting model
Selection of attachments through inheriting model can be useful if
we want to purge attachments that are extended through another
model.

For example, shipping.label (from base_delivery_carrier_label)
inherits from ir.attachment but the attachment itself is linked to
the stock.picking model.
By using inheriting_model defined to shipping.label and setting
model_ids to stock.picking, we can safely select the attachments
linked to stock.pickings that are shipping labels and avoid deleting
any picking list or delivery note reports.
2023-11-28 12:27:14 +01:00
hkpatel aa56d46974 [IMP] autovacuum_message_attachment: black, isort, prettier 2023-11-28 12:27:14 +01:00
Enric Tobella 5a812aab25 [MIG] autovacuum_message_attachment: Migration to 13.0 2023-11-28 12:27:14 +01:00
Enric Tobella 7af9600631 [IMP] autovacuum_message_attachment: black, isort, prettier 2023-11-28 12:27:14 +01:00
Enric Tobella 17c0e7dcc4 [REF] autovacuum_message_attachment: Improve the way we manage domains 2023-11-28 12:27:14 +01:00
Florian da Costa f9e56058e2 Add possibility to delete attachments 2023-11-28 12:23:23 +01:00