mirror of
https://github.com/OCA/bank-payment.git
synced 2025-02-02 10:37:31 +02:00
[FIX] Unclear error message when no period exists for bank statement date
This commit is contained in:
committed by
Guewen Baconnier @ Camptocamp
commit
0b4019c3c3
@@ -263,6 +263,16 @@ class banking_import(osv.osv_memory):
|
||||
('date_stop','>=',statement.date),
|
||||
('special', '=', False)])
|
||||
|
||||
if not period_ids:
|
||||
results.log.append(
|
||||
_('No period found covering statement date %(date)s, '
|
||||
'statement %(id)s skipped') % {
|
||||
'date': statement.date,
|
||||
'id': statement.id,
|
||||
}
|
||||
)
|
||||
continue
|
||||
|
||||
# Create the bank statement record
|
||||
statement_id = statement_obj.create(cursor, uid, dict(
|
||||
name = statement.id,
|
||||
|
||||
Reference in New Issue
Block a user