diff options
Diffstat (limited to 'addons/account_edi_extended/models/account_edi_document.py')
| -rw-r--r-- | addons/account_edi_extended/models/account_edi_document.py | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/addons/account_edi_extended/models/account_edi_document.py b/addons/account_edi_extended/models/account_edi_document.py new file mode 100644 index 00000000..0894b13e --- /dev/null +++ b/addons/account_edi_extended/models/account_edi_document.py @@ -0,0 +1,18 @@ +# -*- coding: utf-8 -*- +# Part of Odoo. See LICENSE file for full copyright and licensing details. +from odoo import models, fields, _ +import logging + +_logger = logging.getLogger(__name__) +DEFAULT_BLOCKING_LEVEL = 'warning' # Keep previous behavior. TODO : when account_edi_extended is merged with account_edi, should be 'error' (document will not be processed again until forced retry or reset to draft) + + +class AccountEdiDocument(models.Model): + _inherit = 'account.edi.document' + + blocking_level = fields.Selection(selection=[('info', 'Info'), ('warning', 'Warning'), ('error', 'Error')], + help="Blocks the document current operation depending on the error severity :\n" + " * Info: the document is not blocked and everything is working as it should.\n" + " * Warning : there is an error that doesn't prevent the current Electronic Invoicing operation to succeed.\n" + " * Error : there is an error that blocks the current Electronic Invoicing operation.") + |
