mirror of
https://github.com/OCA/bank-statement-import.git
synced 2025-01-20 12:37:43 +02:00
Merge pull request #47 from hbrunn/8.0-notifications_one_list
[FIX] have one list of notifications
This commit is contained in:
@@ -94,7 +94,7 @@ class AccountBankStatementImport(models.TransientModel):
|
||||
self._import_statement(stmt_vals))
|
||||
if statement_id:
|
||||
statement_ids.append(statement_id)
|
||||
notifications.append(new_notifications)
|
||||
notifications.extend(new_notifications)
|
||||
if len(statement_ids) == 0:
|
||||
raise Warning(_('You have already imported that file.'))
|
||||
return statement_ids, notifications
|
||||
|
||||
@@ -46,5 +46,7 @@ class AccountBankStatementImport(models.TransientModel):
|
||||
'res_id': statement_id,
|
||||
'type': 'binary',
|
||||
'datas': base64.b64encode(data_file),
|
||||
'description': notifications,
|
||||
'description': '\n'.join(
|
||||
'%(type)s: %(message)' % notification
|
||||
for notification in notifications) or False,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user