【问题标题】:Django Oscar - In checkout process payment details process is getting skippedDjango Oscar - 在结帐过程中付款详细信息过程被跳过
【发布时间】:2019-05-17 20:45:57
【问题描述】:

我在 django-oscar 有一个小型电子商务项目。 在我的结帐过程中付款详细信息过程被跳过,我还没有分叉奥斯卡结帐应用程序仍然收到此错误。

我的控制台响应

[17/Dec/2018 18:37:57] "GET /checkout/payment-method/ HTTP/1.1" 302 0

为什么会重定向到付款预览页面?

任何解决方案或建议

【问题讨论】:

    标签: django django-oscar


    【解决方案1】:

    你必须根据a comment the source子类化oscar.apps.checkout.view.PaymentMethodView:

    class PaymentMethodView(CheckoutSessionMixin, generic.TemplateView):
        ...
    
        def get(self, request, *args, **kwargs):
            # By default we redirect straight onto the payment details view. Shops
            # that require a choice of payment method may want to override this
            # method to implement their specific logic.
            return self.get_success_response()
    

    (如果您已经创建了子类,请发布您的代码)

    【讨论】:

      猜你喜欢
      • 2021-09-08
      • 2018-11-07
      • 2015-09-13
      • 2016-04-09
      • 2017-09-03
      • 2015-07-22
      • 2020-07-10
      • 1970-01-01
      • 2015-04-24
      相关资源
      最近更新 更多