display a time indicator while the delete is being processed
This commit is contained in:
parent
a314892277
commit
bb2ceaeea3
2 changed files with 16 additions and 0 deletions
|
@ -37,6 +37,11 @@ var manageLabels = {
|
||||||
|
|
||||||
$('input#submit').click( function() {
|
$('input#submit').click( function() {
|
||||||
manageLabels.processLabel(manageLabels.selectedRadio);
|
manageLabels.processLabel(manageLabels.selectedRadio);
|
||||||
|
$('span.or').hide();
|
||||||
|
$('a.cancel').hide();
|
||||||
|
$('span#indicator').removeClass('hidden');
|
||||||
|
$('input.submit').addClass('disabledSubmit');
|
||||||
|
$('input.submit').attr('disabled', 'disabled');
|
||||||
});
|
});
|
||||||
|
|
||||||
},
|
},
|
||||||
|
@ -70,11 +75,19 @@ var manageLabels = {
|
||||||
complete: function(request, status) {
|
complete: function(request, status) {
|
||||||
|
|
||||||
if (status == 'success') {
|
if (status == 'success') {
|
||||||
|
$('span.or').show();
|
||||||
|
$('a.cancel').show();
|
||||||
|
$('span#indicator').addClass('hidden');
|
||||||
window.location = $('a.cancel').attr('href');
|
window.location = $('a.cancel').attr('href');
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
alert('Error processing request: the unchecked labels could not be deleted.');
|
alert('Error processing request: the unchecked labels could not be deleted.');
|
||||||
selectedRadio.removeAttr('checked');
|
selectedRadio.removeAttr('checked');
|
||||||
|
$('span.or').show();
|
||||||
|
$('a.cancel').show();
|
||||||
|
$('span#indicator').addClass('hidden');
|
||||||
|
$('input.submit').removeClass('disabledSubmit');
|
||||||
|
$('input.submit').attr('disabled', '');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -46,6 +46,9 @@ Multiple labels exist for this profile but there should only be one. Select the
|
||||||
<input type="button" class="submit" id="submit" value="Save" role="button" role="input" />
|
<input type="button" class="submit" id="submit" value="Save" role="button" role="input" />
|
||||||
<span class="or"> or </span>
|
<span class="or"> or </span>
|
||||||
<a href="${urls.referringPage}" class="cancel" title="cancel" >Cancel</a>
|
<a href="${urls.referringPage}" class="cancel" title="cancel" >Cancel</a>
|
||||||
|
<span id="indicator" class="indicator hidden">
|
||||||
|
<img class="indicator" src="${urls.base}/images/indicatorWhite.gif" /> Your selection is being processed.
|
||||||
|
</span>
|
||||||
</p>
|
</p>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue