diff --git a/rest_framework/templates/rest_framework/fields/attrs.html b/rest_framework/templates/rest_framework/fields/attrs.html deleted file mode 100644 index 1e23c4655..000000000 --- a/rest_framework/templates/rest_framework/fields/attrs.html +++ /dev/null @@ -1 +0,0 @@ -name="{{ field.name }}" {% if field.style.placeholder %}placeholder="{{ field.style.placeholder }}"{% endif %} {% if field.style.rows %}rows="{{ field.style.rows }}"{% endif %} diff --git a/rest_framework/templates/rest_framework/fields/horizontal/input.html b/rest_framework/templates/rest_framework/fields/horizontal/input.html index 6f1a504b5..6621c7e60 100644 --- a/rest_framework/templates/rest_framework/fields/horizontal/input.html +++ b/rest_framework/templates/rest_framework/fields/horizontal/input.html @@ -1,7 +1,9 @@
- {% include "rest_framework/fields/horizontal/label.html" %} + {% if field.label %} + + {% endif %}
- + {% if field.help_text %}

{{ field.help_text }}

{% endif %}
diff --git a/rest_framework/templates/rest_framework/fields/horizontal/label.html b/rest_framework/templates/rest_framework/fields/horizontal/label.html deleted file mode 100644 index bf21f78cc..000000000 --- a/rest_framework/templates/rest_framework/fields/horizontal/label.html +++ /dev/null @@ -1 +0,0 @@ -{% if field.label %}{% endif %} diff --git a/rest_framework/templates/rest_framework/fields/horizontal/select.html b/rest_framework/templates/rest_framework/fields/horizontal/select.html index 10b4b1393..eaa6d575a 100644 --- a/rest_framework/templates/rest_framework/fields/horizontal/select.html +++ b/rest_framework/templates/rest_framework/fields/horizontal/select.html @@ -1,10 +1,12 @@
- {% include "rest_framework/fields/horizontal/label.html" %} + {% if field.label %} + + {% endif %}
diff --git a/rest_framework/templates/rest_framework/fields/horizontal/select_checkbox.html b/rest_framework/templates/rest_framework/fields/horizontal/select_checkbox.html index 6041fa746..ff3fab573 100644 --- a/rest_framework/templates/rest_framework/fields/horizontal/select_checkbox.html +++ b/rest_framework/templates/rest_framework/fields/horizontal/select_checkbox.html @@ -1,5 +1,7 @@
- {% include "rest_framework/fields/horizontal/label.html" %} + {% if field.label %} + + {% endif %}
{% if field.style.inline %} {% for key, text in field.choices.items %} diff --git a/rest_framework/templates/rest_framework/fields/horizontal/select_multiple.html b/rest_framework/templates/rest_framework/fields/horizontal/select_multiple.html index c0dbb989a..3ed2874b2 100644 --- a/rest_framework/templates/rest_framework/fields/horizontal/select_multiple.html +++ b/rest_framework/templates/rest_framework/fields/horizontal/select_multiple.html @@ -1,5 +1,7 @@
- {% include "rest_framework/fields/horizontal/label.html" %} + {% if field.label %} + + {% endif %}
+ {% if field.help_text %}

{{ field.help_text }}

{% endif %}
diff --git a/rest_framework/templates/rest_framework/fields/inline/input.html b/rest_framework/templates/rest_framework/fields/inline/input.html index e4a92ccd1..bdf25ffe6 100644 --- a/rest_framework/templates/rest_framework/fields/inline/input.html +++ b/rest_framework/templates/rest_framework/fields/inline/input.html @@ -1,4 +1,6 @@
- {% include "rest_framework/fields/inline/label.html" %} - + {% if field.label %} + + {% endif %} +
diff --git a/rest_framework/templates/rest_framework/fields/inline/label.html b/rest_framework/templates/rest_framework/fields/inline/label.html deleted file mode 100644 index 7d546a571..000000000 --- a/rest_framework/templates/rest_framework/fields/inline/label.html +++ /dev/null @@ -1 +0,0 @@ -{% if field.label %}{% endif %} diff --git a/rest_framework/templates/rest_framework/fields/inline/select.html b/rest_framework/templates/rest_framework/fields/inline/select.html index eebb91d24..730fcce61 100644 --- a/rest_framework/templates/rest_framework/fields/inline/select.html +++ b/rest_framework/templates/rest_framework/fields/inline/select.html @@ -1,5 +1,7 @@
- {% include "rest_framework/fields/inline/label.html" %} + {% if field.label %} + + {% endif %} {% for key, text in field.choices.items %} diff --git a/rest_framework/templates/rest_framework/fields/inline/select_radio.html b/rest_framework/templates/rest_framework/fields/inline/select_radio.html index 27927a62d..3fffceac4 100644 --- a/rest_framework/templates/rest_framework/fields/inline/select_radio.html +++ b/rest_framework/templates/rest_framework/fields/inline/select_radio.html @@ -1,5 +1,7 @@
- {% include "rest_framework/fields/inline/label.html" %} + {% if field.label %} + + {% endif %} {% for key, text in field.choices.items %}