forms: add class when rendering a widget readonly (#18745)
This commit is contained in:
parent
0d990a433c
commit
1444fa10d1
|
@ -1,5 +1,6 @@
|
|||
{% load qommon %}
|
||||
<div class="widget {{widget.class_name}} {{widget.extra_css_class}}
|
||||
{% if widget.readonly %}widget-readonly{% endif %}
|
||||
{% if widget.get_error %}widget-with-error{% endif %}
|
||||
{% if widget.get_message %}widget-with-message{% endif %}
|
||||
{% if widget.is_required %}widget-required{% else %}widget-optional{% endif %}
|
||||
|
|
Loading…
Reference in New Issue