mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-04-19 03:59:18 -04:00
Put logic into gallery.panel.js so that when the panel is submitted, the submit button is disabled and the user is no longer able to submit multiple clicks.
This commit is contained in:
@@ -50,6 +50,12 @@
|
||||
var self = this;
|
||||
$("#g-panel td form").ajaxForm({
|
||||
dataType: "json",
|
||||
beforeSubmit: function(formData, form, options) {
|
||||
form.find(":submit")
|
||||
.addClass("ui-state-disabled")
|
||||
.attr("disabled", "disabled");
|
||||
return true;
|
||||
},
|
||||
success: function(data) {
|
||||
if (data.form) {
|
||||
$("#g-panel td form").replaceWith(data.form);
|
||||
|
||||
Reference in New Issue
Block a user