Return-Path: X-Original-To: apmail-cloudstack-commits-archive@www.apache.org Delivered-To: apmail-cloudstack-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6B1A710A51 for ; Fri, 3 May 2013 13:14:51 +0000 (UTC) Received: (qmail 82555 invoked by uid 500); 3 May 2013 13:14:50 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 81943 invoked by uid 500); 3 May 2013 13:14:49 -0000 Mailing-List: contact commits-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list commits@cloudstack.apache.org Received: (qmail 80302 invoked by uid 99); 3 May 2013 13:14:44 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 May 2013 13:14:44 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 38F04886062; Fri, 3 May 2013 13:14:44 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: kishan@apache.org To: commits@cloudstack.apache.org Date: Fri, 03 May 2013 13:15:03 -0000 Message-Id: In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [21/50] [abbrv] git commit: updated refs/heads/network_acl to 1609d01 CLOUDSTACK-2041:Granular global parameter- Zone settings Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/61f3f931 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/61f3f931 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/61f3f931 Branch: refs/heads/network_acl Commit: 61f3f931dd9df5354a39cfac0d60fccd782a6aab Parents: 6e2ecff Author: Pranav Saxena Authored: Thu May 2 17:37:01 2013 +0530 Committer: Pranav Saxena Committed: Thu May 2 17:37:01 2013 +0530 ---------------------------------------------------------------------- ui/scripts/system.js | 44 ++++++++++++++++++++++++++++++++++++-------- 1 files changed, 36 insertions(+), 8 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/61f3f931/ui/scripts/system.js ---------------------------------------------------------------------- diff --git a/ui/scripts/system.js b/ui/scripts/system.js index 5c3f359..0b5b3bc 100644 --- a/ui/scripts/system.js +++ b/ui/scripts/system.js @@ -5523,20 +5523,48 @@ // Granular settings for zone settings: { - title: 'label.menu.global.settings', + title: 'Settings', custom: cloudStack.uiCustom.granularSettings({ dataProvider: function(args) { - args.response.success({ - data: [ - { name: 'config.param.1', value: 1 }, - { name: 'config.param.2', value: 2 } - ] - }); + $.ajax({ + url:createURL('listConfigurations&zoneid=' + args.context.physicalResources[0].id), + data: { page: args.page, pageSize: pageSize, listAll: true }, + success:function(json){ + args.response.success({ + data:json.listconfigurationsresponse.configuration + + }); + + }, + + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + + } + }); + }, actions: { edit: function(args) { // call updateZoneLevelParamter - args.response.success(); + var data = { + name: args.data.jsonObj.name, + value: args.data.value + }; + + $.ajax({ + url:createURL('updateConfiguration&zoneid=' + args.context.physicalResources[0].id), + data:data, + success:function(json){ + var item = json.updateconfigurationresponse.configuration; + args.response.success({data:item}); + }, + + error: function(json) { + args.response.error(parseXMLHttpResponse(json)); + } + + }); } } })