diff --git a/ui/scripts/vpc.js b/ui/scripts/vpc.js index 17ea65e6847..ab4d7304710 100644 --- a/ui/scripts/vpc.js +++ b/ui/scripts/vpc.js @@ -367,8 +367,12 @@ }); } else if (data.protocol === 'protocolnumber') { $.extend(data, { - protocolnumber: args.data.protocolnumber + protocol: args.data.protocolnumber, + startport: args.data.startport, + endport: args.data.endport }); + + delete args.data.protocolnumber; } $.ajax({ @@ -1149,10 +1153,17 @@ success:function(json){ var items = json.listnetworkaclsresponse.networkacl.sort(function(a, b) { return a.number >= b.number; + }).map(function(acl) { + if (parseInt(acl.protocol)) { // protocol number + acl.protocolnumber = acl.protocol; + acl.protocol = "protocolnumber"; + } + + return acl; }); args.response.success({ - data:items + data: items /* { cidrlist: '10.1.1.0/24', protocol: 'TCP',