Commit 26992230 authored by Kostas Papadimitriou's avatar Kostas Papadimitriou
Browse files

ui: VM busy indicator in IPs pane

parent 92b55e8b
......@@ -386,6 +386,14 @@
],
'in_progress': [
['ext_status', 'vm'], function() {
var vm_progress = this.get('vm') && this.get('vm').get('in_progress');
if (vm_progress) { return true }
return _.contains(["BUILD", "DISCONNECTING", "CONNECTING"], this.get("ext_status"))
}
],
// check progress of port instance only
'in_progress_no_vm': [
['ext_status'], function() {
return _.contains(["BUILD", "DISCONNECTING", "CONNECTING"], this.get("ext_status"))
}
],
......
......@@ -77,12 +77,16 @@
this.subnet_select.find(".subnet").remove();
_.each(synnefo.config.network_suggested_subnets, function(subnet){
this.subnet_select.append($('<option value='+subnet+' class="subnet">'+subnet+'</option>'));
this.subnet_select.append($('<option value='+subnet+
' class="subnet">'+subnet+
'</option>'));
}, this);
this.type_select.find(".subnet").remove();
_.each(synnefo.config.network_available_types, function(name, value){
this.type_select.append($('<option value='+value+' class="subnet">'+name+'</option>'));
this.type_select.append($('<option value='+value+
' class="subnet">'+name+
'</option>'));
}, this);
if (_.keys(synnefo.config.network_available_types).length <= 1) {
......
......@@ -764,7 +764,7 @@
classes: 'port-item clearfix',
update_in_progress: function() {
if (this.model.get("in_progress")) {
if (this.model.get("in_progress_no_vm")) {
this.set_in_progress();
} else {
this.unset_in_progress();
......
......@@ -7,8 +7,11 @@
data-rv-style="model.vm.status|vm_style"></div>
<h3 class="title" data-rv-text="model.vm.name|truncate 30"></h3>
<h5 class="subtitle">
<span class="key" data-rv-show="model.mac_address">MAC:</span>
<span class="value" data-rv-text="model.mac_address"></span>
<img data-rv-show="model.in_progress"
src="{{ SYNNEFO_IMAGES_URL }}icons/indicators/small/progress.gif"
class="progress-indicator" />
<span data-rv-hide="model.in_progress" class="key">MAC:</span>
<span data-rv-hide="model.in_progress" class="value" data-rv-text="model.mac_address"></span>
</h5>
</div>
</div>
......
......@@ -77,7 +77,7 @@
<div id="vm-port-view-tpl" class="hidden">
<div class="ips" data-rv-collection-view="model.ips|VMPortIpsView"></div>
<div class="clearfix network-header">
<span data-rv-show="model.in_progress|update_in_progress"></span>
<span data-rv-show="model.in_progress_no_vm|update_in_progress"></span>
<img data-rv-src="model.network.is_public|get_network_icon" />
<div class="port" data-rv-text="model.network.name|get_network_name"></div>
<div class="actions-content inline">
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment