CS-15900:InterVlan UI - Confirmation Note on Acquisition of a Public IP Address to a VPC should mention this VPC instead of this Network

This commit is contained in:
Pranav Saxena 2012-08-08 20:29:27 +05:30
parent 8f34776dd8
commit a5f979355b
1 changed files with 10 additions and 4 deletions

View File

@ -157,7 +157,7 @@
};
var networkOfferingObjs = [];
var checkVpc=0;
cloudStack.sections.network = {
title: 'label.network',
id: 'network',
@ -1094,18 +1094,24 @@
addRow: 'true',
preFilter: function(args) {
if('networks' in args.context) { //from Guest Network section
if(args.context.networks[0].vpcid == null) //if it's a non-VPC network, show Acquire IP button
return true;
if(args.context.networks[0].vpcid == null) { //if it's a non-VPC network, show Acquire IP button
checkVpc=0;
return true;
}
else //if it's a VPC network, hide Acquire IP button
return false;
}
else { //from VPC section
checkVpc=1;
return true; //show Acquire IP button
}
},
messages: {
confirm: function(args) {
return 'message.acquire.new.ip';
if(checkVpc == 1)
return 'Please confirm that you would like to acquire a new IP for this VPC';
else
return 'message.acquire.new.ip';
},
notification: function(args) {
return 'label.acquire.new.ip';