Add service status on the web admin
This commit is contained in:
@@ -1,3 +1,40 @@
|
||||
li.status-info {
|
||||
color: #5BC0DE;
|
||||
}
|
||||
|
||||
li.status-warning {
|
||||
color: #D9534F;
|
||||
}
|
||||
|
||||
li.status-danger {
|
||||
color: #D9534F;
|
||||
}
|
||||
|
||||
li.status-success {
|
||||
color: #5CB85C;
|
||||
}
|
||||
|
||||
img#status-loading {
|
||||
display: none;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
img#save-loading {
|
||||
display: none;
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
div#status {
|
||||
display: none;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
div#status ul {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
a.btn-danger span {
|
||||
color: #eee;
|
||||
}
|
||||
|
BIN
sources/public/img/loading.gif
Normal file
BIN
sources/public/img/loading.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 KiB |
@@ -39,4 +39,25 @@ $(document).ready(function() {
|
||||
|
||||
$(choosertxtid).val($(this).val());
|
||||
});
|
||||
|
||||
$('#save').click(function() {
|
||||
$(this).prop('disabled', true);
|
||||
$('#save-loading').show();
|
||||
});
|
||||
|
||||
$('#status .close').click(function() {
|
||||
$(this).parent().hide();
|
||||
});
|
||||
|
||||
$('#statusbtn').click(function() {
|
||||
$('#status-loading').show();
|
||||
|
||||
$.ajax({
|
||||
url: '?/status',
|
||||
}).done(function(data) {
|
||||
$('#status-loading').hide();
|
||||
$('#status-text').html('<ul>' + data + '</ul>');
|
||||
$('#status').show('slow');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user