Tweak form display (cosmetic)

This commit is contained in:
Jeremy Stretch 2019-08-14 09:40:23 -04:00
parent a0d181728a
commit 52de9d227a
2 changed files with 5 additions and 2 deletions

View File

@ -49,7 +49,10 @@ class ScriptVariable:
"""
Render the variable as a Django form field.
"""
return self.form_field(**self.field_attrs)
form_field = self.form_field(**self.field_attrs)
form_field.widget.attrs['class'] = 'form-control'
return form_field
class StringVar(ScriptVariable):

View File

@ -63,7 +63,7 @@
You do not have permission to run scripts.
</div>
{% endif %}
<form action="" method="post">
<form action="" method="post" class="form form-horizontal">
{% csrf_token %}
{% if form %}
{% render_form form %}