Permalink
Browse files

Use non-deprecated bankcard number field

We can do this since we support Oscar 0.6+
  • Loading branch information...
1 parent 6358fca commit 2a3514bc96ffaa6f7a371ad1d48cc15271bf3d89 @codeinthehole codeinthehole committed Jun 10, 2014
Showing with 3 additions and 3 deletions.
  1. +3 −3 datacash/facade.py
View
@@ -106,7 +106,7 @@ def pre_authorise(self, order_number, amount, bankcard=None,
address_data = self.extract_address_data(billing_address)
if bankcard:
response = self.gateway.pre(
- card_number=bankcard.card_number,
+ card_number=bankcard.number,
expiry_date=bankcard.expiry_date,
amount=amount,
currency=currency,
@@ -198,7 +198,7 @@ def authorise(self, order_number, amount, bankcard=None, txn_reference=None,
merchant_ref = self.merchant_reference(order_number, gateway.AUTH)
address_data = self.extract_address_data(billing_address)
if bankcard:
- response = self.gateway.auth(card_number=bankcard.card_number,
+ response = self.gateway.auth(card_number=bankcard.number,
expiry_date=bankcard.expiry_date,
amount=amount,
currency=currency,
@@ -229,7 +229,7 @@ def refund(self, order_number, amount, bankcard=None, txn_reference=None,
currency = settings.DATACASH_CURRENCY
merchant_ref = self.merchant_reference(order_number, gateway.REFUND)
if bankcard:
- response = self.gateway.refund(card_number=bankcard.card_number,
+ response = self.gateway.refund(card_number=bankcard.number,
expiry_date=bankcard.expiry_date,
amount=amount,
currency=currency,

0 comments on commit 2a3514b

Please sign in to comment.