Ejemplo n.º 1
0
    def post(self, request, **kwargs):
        self.init(request, **kwargs)
        submission = self.on_submission(request, **kwargs)  # noqa

        if submission:
            return redirect(submission)

        response, data = submit_paged_form(
            request,
            self.get_forms(),
            self.get_action(),
            object_pk=self.get_object_pk(),
            inject_data=self.get_data(),
            additional_context=self.additional_context,
        )

        # If there are more forms to go through, continue
        if response:
            return response

        self._validated_data = data

        self.post_success_step()

        return redirect(self.get_success_url())
Ejemplo n.º 2
0
    def post(self, request, **kwargs):
        response, data = submit_paged_form(request, self.forms, post_end_user_advisories, inject_data=self.data)

        if response:
            return response

        return end_user_advisory_success_page(request, str(data["end_user_advisory"]["reference_code"]))
Ejemplo n.º 3
0
    def post(request):
        next_form, _ = submit_paged_form(request, add_letter_template(request), post_letter_template,)

        if next_form:
            return next_form

        template_content = get_template_content(request)
        return get_order_paragraphs_page(request, template_content)