fix cfonb import

This commit is contained in:
Luc De Meyer 2020-06-24 23:39:33 +02:00
parent d86bbacb9d
commit 25168cb3c5
3 changed files with 8 additions and 5 deletions

View File

@ -3,7 +3,7 @@
{ {
'name': 'EBICS banking protocol', 'name': 'EBICS banking protocol',
'version': '13.0.1.0.2', 'version': '13.0.1.0.3',
'license': 'LGPL-3', 'license': 'LGPL-3',
'author': 'Noviat', 'author': 'Noviat',
'category': 'Accounting & Finance', 'category': 'Accounting & Finance',

View File

@ -1,4 +1,4 @@
# Copyright 2009-2019 Noviat. # Copyright 2009-2020 Noviat.
# License LGPL-3 or later (http://www.gnu.org/licenses/lpgl). # License LGPL-3 or later (http://www.gnu.org/licenses/lpgl).
import logging import logging
@ -168,7 +168,10 @@ class EbicsFile(models.Model):
import_module = 'account_bank_statement_import_fr_cfonb' import_module = 'account_bank_statement_import_fr_cfonb'
self._check_import_module(import_module) self._check_import_module(import_module)
wiz_model = 'account.bank.statement.import' wiz_model = 'account.bank.statement.import'
wiz_vals = {'data_file': self.data} wiz_vals = {
'attachment_ids': [(0, 0, {'name': self.name,
'datas': self.data,
'store_fname': self.name})]}
wiz = self.env[wiz_model].create(wiz_vals) wiz = self.env[wiz_model].create(wiz_vals)
res = wiz.import_file() res = wiz.import_file()
notifications = [] notifications = []

View File

@ -1,9 +1,9 @@
# Copyright 2009-2019 Noviat. # Copyright 2009-2020 Noviat.
# License LGPL-3 or later (http://www.gnu.org/licenses/lpgl). # License LGPL-3 or later (http://www.gnu.org/licenses/lpgl).
import logging import logging
from odoo import api, fields, models, _ from odoo import _, fields, models
from odoo.exceptions import UserError from odoo.exceptions import UserError
_logger = logging.getLogger(__name__) _logger = logging.getLogger(__name__)