Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(6)  |  Call(6)  |  Derive(0)  |  Import(0)

src/d/j/django-oscar-HEAD/sites/demo/apps/checkout/views.py   django-oscar(Download)
        address_form = BillingAddressForm(shipping_address, request.POST)
 
        if address_form.is_valid() and bankcard_form.is_valid():
            # If both forms are valid, we render the preview view with the
            # forms hidden within the page. This seems odd but means we don't
            self.request.basket)
        address_form = BillingAddressForm(shipping_address, request.POST)
        if address_form.is_valid() and bankcard_form.is_valid():
            # Forms still valid, let's submit an order
            submission = self.build_submission(

src/d/j/django-oscar-paypal-HEAD/sandbox/apps/checkout/views.py   django-oscar-paypal(Download)
        bankcard_form = forms.BankcardForm(request.POST)
        billing_address_form = forms.BillingAddressForm(request.POST)
        if not all([bankcard_form.is_valid(),
                    billing_address_form.is_valid()]):
            # Form validation failed, render page again with errors
        bankcard_form = forms.BankcardForm(request.POST)
        billing_address_form = forms.BillingAddressForm(request.POST)
        if not all([bankcard_form.is_valid(),
                    billing_address_form.is_valid()]):
            messages.error(request, "Invalid submission")

src/d/j/django-oscar-datacash-HEAD/sandbox/apps/checkout/views.py   django-oscar-datacash(Download)
    def handle_payment_details_submission(self, request):
        # Check bankcard form is valid
        bankcard_form = BankcardForm(request.POST)
        if bankcard_form.is_valid():
            return self.render_preview(
    def handle_place_order_submission(self, request):
        bankcard_form = BankcardForm(request.POST)
        if bankcard_form.is_valid():
            submission = self.build_submission(
                payment_kwargs={