Skip to content

Commit a1008f9

Browse files
authored
CLOUDSTACK-10129: Show account, network info in VR list view (#2327)
This shows the owner account and network of a VR in the VR list view, and for VPCs shows the VPC name and redundant state of the VPC rVR. Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
1 parent 475aa03 commit a1008f9

1 file changed

Lines changed: 19 additions & 3 deletions

File tree

ui/scripts/system.js

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,19 @@
2929
var mapRouterType = function (index, router) {
3030
var routerType = _l('label.menu.system');
3131

32-
if (router.projectid) routerType = _l('label.project');
33-
if (router.vpcid) routerType = _l('label.vpc');
34-
if ("isredundantrouter" in router && router.isredundantrouter) routerType = routerType + " (" + router.redundantstate + ")";
32+
if (router.projectid) {
33+
routerType = _l('label.project');
34+
router.account = router.project;
35+
}
36+
37+
if (router.vpcid) {
38+
routerType = _l('label.vpc');
39+
router.guestnetworkname = router.vpcname;
40+
}
41+
42+
if ("isredundantrouter" in router && router.isredundantrouter) {
43+
router.guestnetworkname = router.guestnetworkname + " (" + router.redundantstate + ")";
44+
}
3545

3646
return $.extend(router, {
3747
routerType: routerType
@@ -9479,6 +9489,12 @@
94799489
publicip: {
94809490
label: 'label.public.ip'
94819491
},
9492+
account: {
9493+
label: 'label.account'
9494+
},
9495+
guestnetworkname: {
9496+
label: 'label.network'
9497+
},
94829498
routerType: {
94839499
label: 'label.type'
94849500
},

0 commit comments

Comments
 (0)