mirror of
https://github.com/retspen/webvirtcloud
synced 2024-12-24 15:15:22 +00:00
disable page reloading while migrating vm and pleaseWaitDialog is displayed
fixes: http redirect after migrate does not jump to new compute node
This commit is contained in:
parent
b5f9f638f1
commit
609651d707
2 changed files with 5 additions and 2 deletions
|
@ -1290,13 +1290,14 @@
|
|||
});
|
||||
</script>
|
||||
<script>
|
||||
backgroundJobRunning = false;
|
||||
window.setInterval(function get_status() {
|
||||
var status = {{ status }};
|
||||
$.getJSON('{% url 'inst_status' compute_id vname %}', function (data) {
|
||||
if (data['status'] != status) {
|
||||
if (data['status'] != status && !backgroundJobRunning) {
|
||||
window.location.reload()
|
||||
}
|
||||
})
|
||||
});
|
||||
}, 5000);
|
||||
</script>
|
||||
<script>
|
||||
|
|
|
@ -18,8 +18,10 @@
|
|||
<script>
|
||||
function showPleaseWaitDialog() {
|
||||
$('#pleaseWaitDialog').modal();
|
||||
backgroundJobRunning = true;
|
||||
}
|
||||
function hidePleaseWaitDialog() {
|
||||
$('#pleaseWaitDialog').modal('hide');
|
||||
backgroundJobRunning = false;
|
||||
}
|
||||
</script>
|
||||
|
|
Loading…
Reference in a new issue