diff options
| author | Laurent Smet <las@odoo.com> | 2020-08-31 14:44:34 +0000 |
|---|---|---|
| committer | Laurent Smet <las@odoo.com> | 2020-09-01 07:22:13 +0000 |
| commit | ea1a690d9859eca7df478a6b4de3ed704f13e0f8 (patch) | |
| tree | 053fe28e23636f077d66b3d4720fceafe820ca8c /addons/account_edi_facturx | |
| parent | cd668909f578a7bbe87ab5e6f73df82855809c3b (diff) | |
[FIX] account_edi(_facturx): Don't spam the chatter with xmls
When using FacturX, the user shouldn't see any XML. Indeed, the XMLs are embedded inside the PDF.
Then, this is confusing to see all this XML attachments directly in the chatter.
To avoid that, FacturX is now creating the attachments without any link to the account.move.
Also, when reseting to draft/post multi-times, the old attachments are unlinked because if we want to retrieve it, we could look directly inside the old PDFs.
closes odoo/odoo#56818
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
Diffstat (limited to 'addons/account_edi_facturx')
| -rw-r--r-- | addons/account_edi_facturx/models/account_edi_format.py | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/addons/account_edi_facturx/models/account_edi_format.py b/addons/account_edi_facturx/models/account_edi_format.py index ed2db035fee..d7a9483c2e8 100644 --- a/addons/account_edi_facturx/models/account_edi_format.py +++ b/addons/account_edi_facturx/models/account_edi_format.py @@ -112,8 +112,6 @@ class AccountEdiFormat(models.Model): return self.env['ir.attachment'].create({ 'name': xml_name, 'datas': base64.encodebytes(xml_content), - 'res_model': 'account.move', - 'res_id': invoice._origin.id, 'mimetype': 'application/xml' }) |
