Explorar o código

修复取消paypal周期扣款错误

lang %!s(int64=3) %!d(string=hai) anos
pai
achega
57d13a7d45
Modificáronse 1 ficheiros con 0 adicións e 14 borrados
  1. 0 14
      Controller/PaymentCycle.py

+ 0 - 14
Controller/PaymentCycle.py

@@ -347,13 +347,6 @@ class PaypalCycleNotify(View):
             if not billing_agreement_id:
                 # 记录钩子日志
                 PaypalWebHookEvent.objects.create(**PaypalWebHookEventInsert)
-                #普通支付,更新paypal交易id
-                paymentID = paypal_body.get('parent_payment')
-                if paymentID and paypal_transaction_id:
-                    Order_Model.objects.filter(paymentID=paymentID).update(
-                        updTime=int(time.time()),
-                        trade_no=paypal_transaction_id
-                    )
                 return HttpResponse('success')
 
             agreement_id = paypal_body.get('billing_agreement_id')
@@ -560,13 +553,6 @@ class PaypalCycleNotify(View):
             if not billing_agreement_id:
                 # 记录钩子日志
                 PaypalWebHookEvent.objects.create(**PaypalWebHookEventInsert)
-                # 普通支付,更新paypal交易id
-                paymentID = paypal_body.get('parent_payment')
-                if paymentID and paypal_transaction_id:
-                    Order_Model.objects.filter(paymentID=paymentID).update(
-                        updTime=int(time.time()),
-                        trade_no=paypal_transaction_id
-                    )
                 return HttpResponse('success')
 
             agreement_id = paypal_body.get('billing_agreement_id')