Projet

Général

Profil

0001-systempayv2-map-DENIED-and-CANCELLED-result-codes-17.patch

Benjamin Dauvergne, 11 octobre 2020 09:43

Télécharger (1,32 ko)

Voir les différences:

Subject: [PATCH] systempayv2: map DENIED and CANCELLED result codes (#17065)

 eopayment/systempayv2.py | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
eopayment/systempayv2.py
25 25
import warnings
26 26
from gettext import gettext as _
27 27

  
28
from .common import (PaymentCommon, PaymentResponse, PAID, ERROR, FORM, Form,
29
                     ResponseError, force_text, force_byte)
28
from .common import (PaymentCommon, PaymentResponse, PAID, DENIED, CANCELED,
29
                     ERROR, FORM, Form, ResponseError, force_text, force_byte)
30 30
from .cb import CB_RESPONSE_CODES
31 31

  
32 32
__all__ = ['Payment']
......
452 452

  
453 453
        if fields[VADS_AUTH_RESULT] == '00':
454 454
            result = PAID
455
        elif fields[VADS_AUTH_RESULT] == '05':
456
            result = DENIED
457
        elif fields[VADS_AUTH_RESULT] == '17':
458
            result = CANCELLED
455 459
        else:
456 460
            result = ERROR
457 461
        test = fields[VADS_CTX_MODE] == 'TEST'
458
-