Commit 34e8ee6b by Adam Palay

add extra logging for postpay callbacks from cybersource (ECOM-1034) (ECOM-1089)

parent 984f8732
......@@ -407,6 +407,11 @@ def _record_purchase(params, order):
else:
ccnum = "####"
if settings.FEATURES.get("LOG_POSTPAY_CALLBACKS"):
log.info(
"Order %d purchased with params: %s", order.id, json.dumps(params)
)
# Mark the order as purchased and store the billing information
order.purchase(
first=params.get('req_bill_to_forename', ''),
......@@ -433,6 +438,11 @@ def _record_payment_info(params, order):
Returns:
None
"""
if settings.FEATURES.get("LOG_POSTPAY_CALLBACKS"):
log.info(
"Order %d processed (but not completed) with params: %s", order.id, json.dumps(params)
)
order.processor_reply_dump = json.dumps(params)
order.save()
......
......@@ -347,6 +347,9 @@ FEATURES = {
# Courseware search feature
'ENABLE_COURSEWARE_SEARCH': False,
# log all information from cybersource callbacks
'LOG_POSTPAY_CALLBACKS': True,
}
# Ignore static asset files on import which match this pattern
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment