From 2b48329be522bd8e70643e0d00192f5d37b51324 Mon Sep 17 00:00:00 2001 From: Serghei Mihai Date: Wed, 23 Sep 2015 09:37:03 +0200 Subject: [PATCH] check payment limit for an online payable invoice (#8321) --- passerelle/contrib/teamnet_axel/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/passerelle/contrib/teamnet_axel/utils.py b/passerelle/contrib/teamnet_axel/utils.py index 6662df9..7677ffd 100644 --- a/passerelle/contrib/teamnet_axel/utils.py +++ b/passerelle/contrib/teamnet_axel/utils.py @@ -7,10 +7,10 @@ def normalize_invoice(invoice, family_id): invoice['id'] = '%s-%s' % (family_id, invoice['NOFACTURE']) invoice['display_id'] = invoice['NOFACTURE'] invoice['has_pdf'] = invoice['FPDF'] == 'O' - invoice['online_payment'] = Decimal(invoice['RESTEAPAYER']) != 0 invoice['created'] = datetime.strptime(invoice['FEMISSION'], '%d/%m/%Y') invoice['label'] = invoice['FLIBELLE'] invoice['pay_limit_date'] = datetime.strptime(invoice['FECHEANCE'], '%d/%m/%Y') + invoice['online_payment'] = Decimal(invoice['RESTEAPAYER']) != 0 or invoice['pay_limit_date'] >= datetime.today() return invoice def normalize_person(person): -- 2.5.3