From f931d54b7b99730683e4d46bf7ddfb44673b3939 Mon Sep 17 00:00:00 2001 From: Lucas Theis Date: Thu, 24 Oct 2024 16:47:09 +0100 Subject: [PATCH] Fix TemplateDoesNotExist when using MultiField (#75) --- .../bootstrap5/layout/multifield.html | 30 ++----------------- .../templates/bootstrap5/multifield.html | 5 ++++ 2 files changed, 8 insertions(+), 27 deletions(-) create mode 100644 crispy_bootstrap5/templates/bootstrap5/multifield.html diff --git a/crispy_bootstrap5/templates/bootstrap5/layout/multifield.html b/crispy_bootstrap5/templates/bootstrap5/layout/multifield.html index 0a2c050..9234c82 100644 --- a/crispy_bootstrap5/templates/bootstrap5/layout/multifield.html +++ b/crispy_bootstrap5/templates/bootstrap5/layout/multifield.html @@ -1,27 +1,3 @@ -{% load crispy_forms_field %} - -{% if field.is_hidden %} - {{ field }} -{% else %} - - {% if field.label %} - - {% endif %} - -{% endif %} +
+ {{ fields_output }} +
diff --git a/crispy_bootstrap5/templates/bootstrap5/multifield.html b/crispy_bootstrap5/templates/bootstrap5/multifield.html new file mode 100644 index 0000000..ad7a87e --- /dev/null +++ b/crispy_bootstrap5/templates/bootstrap5/multifield.html @@ -0,0 +1,5 @@ +{% load crispy_forms_field %} + +
+ {% include 'bootstrap5/field.html' %} +