Skip to content

Commit f2871c5

Browse files
committed
Update 5.0 release notes
1 parent fa4edf2 commit f2871c5

1 file changed

Lines changed: 45 additions & 5 deletions

File tree

docs/releases/v5.0.0.rst

Lines changed: 45 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,48 @@ For most sites, no action is required, as the organization data is automatically
3838

3939
However, if you were previously using custom organization data on many separate pages, you'll need to follow the `wagtail-seo 3 upgrade instructions <https://docs.coderedcorp.com/wagtail-seo/getting-started/migration-3.html>`_
4040

41-
Preview options removed from Pages and Blocks
42-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
41+
42+
Form template has changed
43+
~~~~~~~~~~~~~~~~~~~~~~~~~
44+
45+
If you have any custom form page templates, they will need updated. Form page template and miniview templates have changed to support new reCAPTCHA fields.
46+
47+
* Form ID changed to: ``<form id={{ page.get_form_id }}>``.
48+
* Removed ``{% block captcha %}`` and ``form_honeypot.html``.
49+
* Replace submit button with ``{% include "coderedcms/includes/form_button.html" %}``.
50+
51+
See diff below:
52+
53+
.. code-block:: diff
54+
55+
{{ block.super }}
56+
{% if page.form_live %}
57+
<div class="container my-5">
58+
- <form class="{{ page.form_css_class }}" id="{{ page.form_id }}" action="{% pageurl self %}" method="POST" {% if form|is_file_form %}enctype="multipart/form-data"{% endif %}>
59+
+ <form class="{{ page.form_css_class }}" id="{{ page.get_form_id }}" action="{% pageurl self %}" method="POST" {% if form|is_file_form %}enctype="multipart/form-data"{% endif %}>
60+
{% csrf_token %}
61+
{% bootstrap_form form layout="horizontal" %}
62+
-
63+
- {% block captcha %}
64+
- {% if page.spam_protection %}
65+
- {% include "coderedcms/includes/form_honeypot.html" %}
66+
- {% endif %}
67+
- {% endblock %}
68+
-
69+
<div class="row">
70+
<div class="{{'horizontal_label_class'|bootstrap_settings}}"></div>
71+
<div class="{{'horizontal_field_class'|bootstrap_settings}}">
72+
- <button type="submit" class="btn {{page.button_size}} {{page.button_style}} {{page.button_css_class}}">
73+
- {{ page.button_text }}
74+
- </button>
75+
+ {% include "coderedcms/includes/form_button.html" %}
76+
</div>
77+
</div>
78+
</form>
79+
80+
81+
``show_*`` options removed from Pages and Blocks
82+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4383

4484
For most sites, no action is required as these have been deprecated and replaced by miniview templates back in :doc:`version 2.1 <v2.1.0>`.
4585

@@ -70,10 +110,10 @@ Migrations
70110

71111
After upgrading, be sure to generate and apply new migrations as so:
72112

73-
.. code-block::
113+
.. code-block:: console
74114
75-
python manage.py makemigrations
76-
python manage.py migrate
115+
$ python manage.py makemigrations
116+
$ python manage.py migrate
77117
78118
79119
Thank you!

0 commit comments

Comments
 (0)