Skip to content

Commit d0c0405

Browse files
committed
Render lecture attendance with Crispy Forms
This doesn't change behavior at all, but it does silence a warning that the default `form` rendering on Django 4 is deprecated and instead must be explicit. This helps unblock an upgrade to Django 4.2.
1 parent 9649037 commit d0c0405

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ws/templates/for_templatetags/lecture_attendance.html

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{% load crispy_forms_tags %}
12
{% if attended_lectures %}
23
<h3>Lecture Attendance</h3>
34
<p>
@@ -13,7 +14,7 @@ <h3>Lecture Attendance</h3>
1314
{% elif can_set_attendance %} {# User (or chair) can mark attendance. #}
1415
<form method="post" action="{% url 'lecture_attendance' %}">
1516
{% csrf_token %}
16-
{{ form }}
17+
{{ form|crispy }}
1718
<div class="panel panel-primary">
1819
<div class="panel-heading">
1920
Winter School lecture attendance

0 commit comments

Comments
 (0)