From 872f3fff996f1c8308386b252a876228206725fb Mon Sep 17 00:00:00 2001 From: Maxime Pommier Date: Wed, 17 Jul 2019 09:57:09 +0200 Subject: [PATCH] [fortuneo] Add bdate --- modules/fortuneo/pages/accounts_list.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/modules/fortuneo/pages/accounts_list.py b/modules/fortuneo/pages/accounts_list.py index 9ae95a975a..5e4e5be86f 100644 --- a/modules/fortuneo/pages/accounts_list.py +++ b/modules/fortuneo/pages/accounts_list.py @@ -291,6 +291,12 @@ def get_operations(self): amount = tables[i].xpath("./td[5]/text() | ./td[6]/text()") operation.parse(date=date_oper, raw=label, vdate=date_val) + + # There is no difference between card transaction and deferred card transaction + # on the history. + if operation.type == FrenchTransaction.TYPE_CARD: + operation.bdate = operation.rdate + # Needed because operation.parse overwrite operation.label # Theses lines must run after operation.parse. if tables[i].xpath("./td[4]/div/text()"): @@ -327,7 +333,7 @@ def get_operations(self): tr = Transaction() tr.parse(date=date, raw=raw) - tr.rdate = tr.parse_date(rdate) + tr.rdate = tr.bdate = tr.parse_date(rdate) tr.type = tr.TYPE_DEFERRED_CARD if credit: tr.amount = CleanDecimal(None, replace_dots=True).filter(credit) -- GitLab