CLOUDSTACK-2678: portable IP ranges - regions detailView - add viewAll path to Portable IP Ranges listView.
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/3d16e825 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/3d16e825 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/3d16e825 Branch: refs/heads/vmware-storage-motion Commit: 3d16e82547c311c1f0cd22065d587556d70d511a Parents: 6975f6b Author: Jessica Wang <[email protected]> Authored: Fri May 24 10:33:28 2013 -0700 Committer: Jessica Wang <[email protected]> Committed: Fri May 24 10:33:28 2013 -0700 ---------------------------------------------------------------------- ui/scripts/regions.js | 41 ++++++++++++++++++++++++++++++++++++++--- 1 files changed, 38 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/3d16e825/ui/scripts/regions.js ---------------------------------------------------------------------- diff --git a/ui/scripts/regions.js b/ui/scripts/regions.js index 2bbbbee..e86fd28 100644 --- a/ui/scripts/regions.js +++ b/ui/scripts/regions.js @@ -116,7 +116,10 @@ }, detailView: { name: 'Region details', - viewAll: { path: 'regions.GSLB', label: 'GSLB' }, + viewAll: [ + { path: 'regions.GSLB', label: 'GSLB' }, + { path: 'regions.portableIpRanges', label: 'Portable IP' } + ], actions: { edit: { label: 'label.edit.region', @@ -451,8 +454,40 @@ } } }, - - lbUnderGSLB: { + + portableIpRanges: { + id: 'portableIpRanges', + type: 'select', + title: 'Portable IP Ranges', + listView: { + id: 'portableIpRanges', + label: 'Portable IP Ranges', + fields: { + name: { label: 'label.name' }, + gslbdomainname: { label: 'GSLB Domain Name' }, + gslblbmethod: { label: 'Algorithm' } + }, + dataProvider: function(args) { + $.ajax({ + url: createURL('listPortableIpRanges'), + data: { + regionid: args.context.regions[0].id + }, + success: function(json) { + var items = json.listportableipresponse.portableip; + args.response.success({ + data: items + }); + }, + error: function(json) { + args.response.error(parseXMLHttpResponse(json)); + } + }); + } + } + }, + + lbUnderGSLB: { id: 'lbUnderGSLB', type: 'select', title: 'assigned load balancing',
