Skip to content

Commit dc505c2

Browse files
committed
ui: allow admin option to specify if they want network usage to be hidden
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
1 parent beb0422 commit dc505c2

3 files changed

Lines changed: 18 additions & 0 deletions

File tree

ui/l10n/en.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1172,6 +1172,7 @@ var dictionary = {
11721172
"label.network.device.type":"Network Device Type",
11731173
"label.network.domain":"Network Domain",
11741174
"label.network.domain.text":"Network domain",
1175+
"label.network.hideipaddressusage":"Hide IP Address Usage",
11751176
"label.network.id":"Network ID",
11761177
"label.network.label.display.for.blank.value":"Use default gateway",
11771178
"label.network.limits":"Network limits",

ui/scripts/docs.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -506,6 +506,10 @@ cloudStack.docs = {
506506
desc: 'If you want to assign a special domain name to this guest VM network, specify the DNS suffix',
507507
externalLink: ''
508508
},
509+
helpGuestNetworkHideIpAddressUsage: {
510+
desc: 'If you want the IP address usage records hidden for the network',
511+
externalLink: ''
512+
},
509513
// Add host
510514
helpHostZone: {
511515
desc: 'The zone where you want to add the host',

ui/scripts/sharedFunctions.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -704,7 +704,16 @@ var addGuestNetworkDialog = {
704704
networkdomain: {
705705
label: 'label.network.domain',
706706
docID: 'helpGuestNetworkZoneNetworkDomain'
707+
},
708+
709+
hideipaddressusage: {
710+
label: 'label.network.hideipaddressusage',
711+
dependsOn: ['zoneId', 'physicalNetworkId', 'scope'],
712+
isBoolean: true,
713+
isChecked: false,
714+
docID: 'helpGuestNetworkHideIpAddressUsage'
707715
}
716+
708717
}
709718
},
710719

@@ -795,6 +804,10 @@ var addGuestNetworkDialog = {
795804
if (args.data.networkdomain != null && args.data.networkdomain.length > 0){
796805
array1.push("&networkdomain=" + encodeURIComponent(args.data.networkdomain));
797806
}
807+
if (args.data.hideipaddressusage != null && args.data.hideipaddressusage) {
808+
array1.push("&hideipaddressusage=true")
809+
}
810+
798811
$.ajax({
799812
url: createURL("createNetwork" + array1.join("")),
800813
dataType: "json",

0 commit comments

Comments
 (0)