mirror of
https://github.com/retspen/webvirtcloud
synced 2024-12-24 23:25:24 +00:00
please wait dialog added on migrate/clone event
This commit is contained in:
parent
8de4c6b131
commit
fc71884cd4
2 changed files with 28 additions and 2 deletions
|
@ -2,6 +2,7 @@
|
|||
{% load i18n %}
|
||||
{% block title %}{% trans "Instance" %} - {{ vname }}{% endblock %}
|
||||
{% block content %}
|
||||
{% include 'pleasewaitdialog.html' %}
|
||||
<!-- Page Heading -->
|
||||
<div class="row">
|
||||
<table>
|
||||
|
@ -771,7 +772,7 @@
|
|||
</div>
|
||||
</div>
|
||||
{% ifequal status 5 %}
|
||||
<button type="submit" class="btn btn-lg btn-success pull-right" name="clone">{% trans "Clone" %}</button>
|
||||
<button type="submit" class="btn btn-lg btn-success pull-right" name="clone" onclick="showPleaseWaitDialog();">{% trans "Clone" %}</button>
|
||||
{% else %}
|
||||
<button class="btn btn-lg btn-success pull-right disabled" name="clone">{% trans "Clone" %}</button>
|
||||
{% endifequal %}
|
||||
|
@ -822,7 +823,7 @@
|
|||
</div>
|
||||
</div>
|
||||
{% if computes_count != 1 %}
|
||||
<button type="submit" class="btn btn-lg btn-success pull-right" name="migrate">{% trans "Migrate" %}</button>
|
||||
<button type="submit" class="btn btn-lg btn-success pull-right" name="migrate" onclick="showPleaseWaitDialog();">{% trans "Migrate" %}</button>
|
||||
{% else %}
|
||||
<button class="btn btn-lg btn-success pull-right disabled">{% trans "Migrate" %}</button>
|
||||
{% endif %}
|
||||
|
|
25
templates/pleasewaitdialog.html
Normal file
25
templates/pleasewaitdialog.html
Normal file
|
@ -0,0 +1,25 @@
|
|||
{% load i18n %}
|
||||
<!-- Please wait dialog -->
|
||||
<div class="modal fade" id="pleaseWaitDialog" tabindex="-1" role="dialog" aria-labelledby="pleaseWaitDialogLabel" data-backdrop="static" data-keyboard="false">
|
||||
<div class="modal-dialog modal-sm">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h4 class="modal-title">{% trans "Processing" %}...</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="progress">
|
||||
<div class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="10" aria-valuemin="0" aria-valuemax="10" style="width:100%">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
function showPleaseWaitDialog() {
|
||||
$('#pleaseWaitDialog').modal();
|
||||
}
|
||||
function hidePleaseWaitDialog() {
|
||||
$('#pleaseWaitDialog').modal('hide');
|
||||
}
|
||||
</script>
|
Loading…
Reference in a new issue