Commit 66100895 by Kálmán Viktor

dashboard: fix operation form getting submitted twice

parent a691294f
...@@ -101,7 +101,7 @@ $(function() { ...@@ -101,7 +101,7 @@ $(function() {
}); });
$("body").on("click", "#op-form-send", function() { $("body").on("click", "#mass-op-form-send", function() {
var url = $(this).closest("form").prop("action"); var url = $(this).closest("form").prop("action");
$(this).find("i").prop("class", "fa fa-fw fa-spinner fa-spin"); $(this).find("i").prop("class", "fa fa-fw fa-spinner fa-spin");
......
...@@ -31,7 +31,7 @@ Do you want to perform the <strong>{{op}}</strong> operation on the following {{ ...@@ -31,7 +31,7 @@ Do you want to perform the <strong>{{op}}</strong> operation on the following {{
<div class="pull-right"> <div class="pull-right">
<a class="btn btn-default" href="{% url "dashboard.views.vm-list" %}" <a class="btn btn-default" href="{% url "dashboard.views.vm-list" %}"
data-dismiss="modal">{% trans "Cancel" %}</a> data-dismiss="modal">{% trans "Cancel" %}</a>
<button class="btn btn-{{ opview.effect }}" type="submit" id="op-form-send"> <button class="btn btn-{{ opview.effect }}" type="submit" id="mass-op-form-send">
{% if opview.icon %}<i class="fa fa-fw fa-{{opview.icon}}"></i> {% endif %}{{ opview.name|capfirst }} {% if opview.icon %}<i class="fa fa-fw fa-{{opview.icon}}"></i> {% endif %}{{ opview.name|capfirst }}
</button> </button>
</div> </div>
......
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 sign in to comment