- Timestamp:
- 11 Jan 2016, 06:09:59 (9 years ago)
- Location:
- main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/interswitch
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/interswitch/browser.py
r13581 r13584 119 119 self.context, self.product_id, 120 120 self.gateway_host, self.gateway_url, 121 self.https, self.mac )121 self.https, self.mac, False) 122 122 student.writeLogMessage(self, log) 123 123 if not success: … … 156 156 self.context, self.product_id, 157 157 self.gateway_host, self.gateway_url, 158 self.https, self.mac )158 self.https, self.mac, False) 159 159 applicant.writeLogMessage(self, log) 160 160 if not success: … … 193 193 self.context, self.product_id, 194 194 self.gateway_host, self.gateway_url, 195 self.https, self.mac )195 self.https, self.mac, True) 196 196 student.writeLogMessage(self, log) 197 197 if not success: … … 226 226 self.context, self.product_id, 227 227 self.gateway_host, self.gateway_url, 228 self.https, self.mac )228 self.https, self.mac, True) 229 229 applicant.writeLogMessage(self, log) 230 230 if not success: -
main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/interswitch/helpers.py
r13581 r13584 93 93 return parsed_json 94 94 95 def query_interswitch_SOAP(payment, product_id, host, url, https ):95 def query_interswitch_SOAP(payment, product_id, host, url, https, verify): 96 96 sr = get_SOAP_response(product_id, payment.p_id, host, url, https) 97 97 if sr.startswith('Connection error'): … … 132 132 return False, msg, log 133 133 payment.p_state = 'paid' 134 payment.payment_date = datetime.utcnow() 134 if not verify: 135 payment.payment_date = datetime.utcnow() 135 136 msg = _('Successful callback received.') 136 137 log = 'valid callback for %s payment %s: %s' % ( … … 139 140 return True, msg, log 140 141 141 def query_interswitch(payment, product_id, host, url, https, mac ):142 def query_interswitch(payment, product_id, host, url, https, mac, verify): 142 143 # If no mac mac key is given, fall back to deprecated SOAP method 143 144 # (Uniben, AAUA, FCEOkene). 144 145 if mac == None: 145 return query_interswitch_SOAP(payment, product_id, host, url, https) 146 return query_interswitch_SOAP( 147 payment, product_id, host, url, https, verify) 146 148 jr = get_JSON_response(product_id, payment.p_id, host, url, 147 149 https, mac, payment.amount_auth) … … 196 198 return False, msg, log 197 199 payment.p_state = 'paid' 198 payment.payment_date = datetime.utcnow() 200 if not verify: 201 payment.payment_date = datetime.utcnow() 199 202 msg = _('Successful callback received') 200 203 log = 'valid callback for %s payment %s: %s' % (
Note: See TracChangeset for help on using the changeset viewer.