pull/2967/head
Matt Westcott 2016-09-01 16:20:57 +01:00
rodzic 0e052f3db8
commit 1d5475672e
3 zmienionych plików z 23 dodań i 0 usunięć
docs
reference/contrib
releases

Wyświetl plik

@ -7,6 +7,7 @@ Changelog
* Elasticsearch 2 support (Karl Hobley)
* Added support for AWS CloudFront in frontend cache invalidation module (Rob Moorman)
* Unpublishing a page now gives the option to unpublish subpages too (Jordi Joan)
* The `wagtailforms` module now provides a `FormSubmissionPanel` for displaying details of form submissions (João Luiz Lorencetti)
* The Wagtail version number can now be obtained as a tuple using `from wagtail import VERSION` (Tim Heap)
* ``send_mail`` logic has been moved from ``AbstractEmailForm.process_form_submission`` into ``AbstractEmailForm.send_mail``. Now it's easier to override this logic (Tim Leguijt)
* Fix: Migrations for wagtailcore and project template are now reversible (Benjamin Bach)

Wyświetl plik

@ -75,3 +75,24 @@ You now need to create two templates named ``form_page.html`` and ``form_page_la
</html>
``form_page_landing.html`` is a regular Wagtail template, displayed after the user makes a successful form submission.
.. _wagtailforms_formsubmissionpanel:
Displaying form submission information
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
``FormSubmissionsPanel`` can be added to your page's panel definitions to display the number of form submissions and the time of the most recent submission, along with a quick link to access the full submission data:
.. code-block:: python
from wagtail.wagtailforms.edit_handlers import FormSubmissionsPanel
class FormPage(AbstractEmailForm):
# ...
content_panels = AbstractEmailForm.content_panels + [
FormSubmissionsPanel(),
FieldPanel('intro', classname="full"),
# ...
]

Wyświetl plik

@ -37,6 +37,7 @@ Unpublishing a page now gives the option to unpublish its subpages at the same t
Minor features
~~~~~~~~~~~~~~
* The ``wagtailforms`` module now provides a ``FormSubmissionPanel`` for displaying details of form submissions; see :ref:`wagtailforms_formsubmissionpanel` for documentation. (João Luiz Lorencetti)
* The Wagtail version number can now be obtained as a tuple using ``from wagtail import VERSION`` (Tim Heap)
* ``send_mail`` logic has been moved from ``AbstractEmailForm.process_form_submission`` into ``AbstractEmailForm.send_mail``. Now it's easier to override this logic (Tim Leguijt)