From 38856458827b7fd0df071dddbddca7b9e337721a Mon Sep 17 00:00:00 2001 From: Nischal lamichhane <108085352+hehenischal@users.noreply.github.com> Date: Fri, 14 Feb 2025 01:06:19 +0545 Subject: [PATCH] critical: no 'add' pages is opening in django 5.1 this is because although the 'length_is' filter was deprecated in 4.2. the code is permanently removed in django 5.1 this is causing critical issue where you cannot open any 'add/update' pages --- adminlte3_theme/templates/admin/includes/fieldset.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/adminlte3_theme/templates/admin/includes/fieldset.html b/adminlte3_theme/templates/admin/includes/fieldset.html index c32e61a..798fc9a 100644 --- a/adminlte3_theme/templates/admin/includes/fieldset.html +++ b/adminlte3_theme/templates/admin/includes/fieldset.html @@ -13,8 +13,8 @@

{% if fieldset.name %}{{ fieldset.name }}{% endif %}

{% for line in fieldset %}
- {% if line.fields|length_is:'1' %}{{ line.errors }}{% endif %} + class="form-group row form-row{% if line.fields|length == 1 and line.errors %} has_error errors{% endif %}{% if not line.has_visible_field %} hidden{% endif %}{% for field in line %}{% if field.field.name %} field-{{ field.field.name }}{% endif %}{% endfor %}"> + {% if line.fields|length == 1 %}{{ line.errors }}{% endif %} {% for field in line %}