[FIX] l10n_it_edi_sdicoop: when an edi is successfully sent, it should return {'success': True}

closes odoo/odoo#74744

Signed-off-by: Josse Colpaert <jco@openerp.com>
This commit is contained in:
Benjamin Frantzen (bfr)
2021-08-05 09:27:42 +00:00
parent 443b38088b
commit 6811c374fb
@@ -219,7 +219,7 @@ class AccountEdiFormat(models.Model):
elif state == 'notificaEsito':
outcome = response_tree.find('Esito').text
if outcome == 'EC01':
to_return[invoice] = {'attachment': invoice.l10n_it_edi_attachment_id}
to_return[invoice] = {'attachment': invoice.l10n_it_edi_attachment_id, 'success': True}
else: # ECO2
to_return[invoice] = {'error': _('The invoice was refused by the addressee.'), 'blocking_level': 'error'}
elif state == 'NotificaDecorrenzaTermini':