diff --git a/eopayment/__init__.py b/eopayment/__init__.py index 2d47bf1..4f3a039 100644 --- a/eopayment/__init__.py +++ b/eopayment/__init__.py @@ -103,7 +103,7 @@ class Payment(object): ''' return self.backend.request(amount, **kwargs) - def response(self, query_string): + def response(self, query_string, **kwargs): ''' Process a response from the Bank API. It must be used on the URL where the user browser of the payment server is going to post the @@ -136,4 +136,4 @@ class Payment(object): your site as a web service. ''' - return self.backend.response(query_string) + return self.backend.response(query_string, **kwargs) diff --git a/eopayment/dummy.py b/eopayment/dummy.py index bfb073a..8c0f367 100644 --- a/eopayment/dummy.py +++ b/eopayment/dummy.py @@ -96,7 +96,7 @@ class Payment(PaymentCommon): url = '%s?%s' % (SERVICE_URL, urllib.urlencode(query)) return transaction_id, URL, url - def response(self, query_string, logger=LOGGER): + def response(self, query_string, logger=LOGGER, **kwargs): form = parse_qs(query_string) transaction_id = form.get('transaction_id',[''])[0] form[self.BANK_ID] = transaction_id diff --git a/eopayment/ogone.py b/eopayment/ogone.py index 4ccb2f9..1bfdcb4 100644 --- a/eopayment/ogone.py +++ b/eopayment/ogone.py @@ -506,7 +506,7 @@ class Payment(PaymentCommon): 'value': params[key]} for key in params]) return reference, FORM, form - def response(self, query_string): + def response(self, query_string, **kwargs): params = urlparse.parse_qs(query_string, True) params = dict((key.upper(), params[key][0]) for key in params) reference = params['ORDERID'] diff --git a/eopayment/sips.py b/eopayment/sips.py index da3fcca..028a8f6 100644 --- a/eopayment/sips.py +++ b/eopayment/sips.py @@ -150,7 +150,7 @@ class Payment(PaymentCommon): else: raise RuntimeError('sips/request returned -1: %s' % error) - def response(self, query_string): + def response(self, query_string, **kwargs): form = urlparse.parse_qs(query_string) params = {'message': form[DATA][0]} result = self.execute('response', params) diff --git a/eopayment/spplus.py b/eopayment/spplus.py index 05fbbfb..57e1e5c 100644 --- a/eopayment/spplus.py +++ b/eopayment/spplus.py @@ -154,7 +154,7 @@ next_url=%s' % (amount, email, next_url)) logger.debug('full url %s' % url) return reference, URL, url - def response(self, query_string, logger=LOGGER): + def response(self, query_string, logger=LOGGER, **kwargs): form = urlparse.parse_qs(query_string) for key, value in form.iteritems(): form[key] = value[0] diff --git a/eopayment/systempayv2.py b/eopayment/systempayv2.py index 05d4a8e..f1786da 100644 --- a/eopayment/systempayv2.py +++ b/eopayment/systempayv2.py @@ -309,7 +309,7 @@ class Payment(PaymentCommon): self.logger.debug('%s transaction id: %s', __name__, transaction_id) return transaction_id, URL, url - def response(self, query_string): + def response(self, query_string, **kwargs): fields = urlparse.parse_qs(query_string, True) for key, value in fields.iteritems(): fields[key] = value[0] diff --git a/eopayment/tipi.py b/eopayment/tipi.py index 3372efe..7bb5aaf 100644 --- a/eopayment/tipi.py +++ b/eopayment/tipi.py @@ -121,7 +121,7 @@ class Payment(PaymentCommon): url = '%s?%s' % (self.service_url, urlencode(params)) return transaction_id, URL, url - def response(self, query_string): + def response(self, query_string, **kwargs): fields = parse_qs(query_string, True) for key, value in fields.iteritems(): fields[key] = value[0]