Skip to content

Commit

Permalink
[FIX] l10n_it_fatturapa_pec: Receive base64 attachments OCA#2915 Co-a…
Browse files Browse the repository at this point in the history
…uthored-by: odooNextev <[email protected]>
  • Loading branch information
SirTakobi authored and odooNextev committed Jul 21, 2023
1 parent 6bf3cad commit a7c4da2
Show file tree
Hide file tree
Showing 4 changed files with 550 additions and 3 deletions.
3 changes: 2 additions & 1 deletion l10n_it_fatturapa_pec/models/mail_thread.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# Copyright 2018 Sergio Corato (https://efatto.it)
# Copyright 2018 Lorenzo Battistini <https://github.com/eLBati>

import base64
import logging
import re

Expand Down Expand Up @@ -220,7 +221,7 @@ def create_fatturapa_attachment_in(self, attachment, message_dict=None):
# See check_fetch_pec_server_id
company_id = sdi_chan.company_id.id
file_name_content_dict = {
attachment.name: attachment.datas,
attachment.name: base64.b64decode(attachment.datas),
}
default_values = {
"company_id": company_id,
Expand Down
Loading

0 comments on commit a7c4da2

Please sign in to comment.