Commit 697534c7 authored by dani2612's avatar dani2612

modificato il form in modo da inserire il button nell'input

parent 707e6444
......@@ -28,14 +28,34 @@
{% endblock %}
{% block content %}
<form action="" method="post">{% csrf_token %}
<button class="btn btn-primary" type="button" data-toggle="modal" data-target="#qr-scan">
<span class="glyphicon glyphicon-qrcode" aria-hidden="true"></span><span class="sr-only">Read QR code</span>
</button>
{% bootstrap_form form %}
{% for field in form %}
{% if field.name == "id" %}
{% bootstrap_field field addon_after='<span class="input-group-btn"><button class="btn btn-primary" type="button" data-toggle="modal" data-target="#qr-scan"><span class="glyphicon glyphicon-qrcode" aria-hidden="true"></span><span class="sr-only">Read QR code</span></button></span>' %}
{% else %}
{% bootstrap_field field %}
{% endif %}
{% endfor %}
{% buttons %}
<button type="submit" class="btn btn-primary">
{% bootstrap_icon "star" %} Submit
</button>
{% endbuttons %}
</form>
</form>
{% endblock %}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment