Show spinner for initial ajax query
This commit is contained in:
parent
926cd27136
commit
f7a4266276
@ -74,12 +74,6 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$.getJSON('/node/keywords', function(keywords) {
|
|
||||||
for (var i = 0; i < keywords.length; ++i) {
|
|
||||||
var properties = { value: keywords[i], text: keywords[i] };
|
|
||||||
$('#keyword').append($('<option></option>', properties));
|
|
||||||
}
|
|
||||||
|
|
||||||
$(document).on({
|
$(document).on({
|
||||||
ajaxStart: function() {
|
ajaxStart: function() {
|
||||||
$('#spinner').show();
|
$('#spinner').show();
|
||||||
@ -89,6 +83,12 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
$.getJSON('/node/keywords', function(keywords) {
|
||||||
|
for (var i = 0; i < keywords.length; ++i) {
|
||||||
|
var properties = { value: keywords[i], text: keywords[i] };
|
||||||
|
$('#keyword').append($('<option></option>', properties));
|
||||||
|
}
|
||||||
|
|
||||||
$('#search').prop('disabled', false);
|
$('#search').prop('disabled', false);
|
||||||
$('#search').click(onSearch);
|
$('#search').click(onSearch);
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user