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 90C12113B4 for ; Mon, 13 May 2013 18:13:09 +0000 (UTC) Received: (qmail 43748 invoked by uid 500); 13 May 2013 18:13:07 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 43672 invoked by uid 500); 13 May 2013 18:13:07 -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 43521 invoked by uid 99); 13 May 2013 18:13:07 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 13 May 2013 18:13:07 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id E145888FA74; Mon, 13 May 2013 18:13:06 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: bfederle@apache.org To: commits@cloudstack.apache.org Date: Mon, 13 May 2013 18:13:12 -0000 Message-Id: <7d57e194e5fd47e19e9e7c01cc925e1f@git.apache.org> In-Reply-To: <6af48cf7f9fb4512ba34bd63f1b3cab4@git.apache.org> References: <6af48cf7f9fb4512ba34bd63f1b3cab4@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [07/30] git commit: updated refs/heads/ui-vpc-redesign to 9ac67b8 Infrastructure UI plugin API: Add 'resource' method Add new method 'infrastructure.resource' for retrieving resource objects from the infrastructure section. Specify the type as a string (i.e, 'pod' 'cluster' or 'host') and the entire resource object will be returned, including listView, actions, createForm, etc. Updating the data in this resource will automatically update the UI. Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/1c482b5c Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/1c482b5c Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/1c482b5c Branch: refs/heads/ui-vpc-redesign Commit: 1c482b5c3bc85e549b457070e5cd901bb181c3f9 Parents: d53d06c Author: Brian Federle Authored: Tue Apr 23 14:40:33 2013 -0700 Committer: Brian Federle Committed: Tue Apr 23 14:40:33 2013 -0700 ---------------------------------------------------------------------- ui/modules/infrastructure/infrastructure.js | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1c482b5c/ui/modules/infrastructure/infrastructure.js ---------------------------------------------------------------------- diff --git a/ui/modules/infrastructure/infrastructure.js b/ui/modules/infrastructure/infrastructure.js index 8292896..ad43108 100644 --- a/ui/modules/infrastructure/infrastructure.js +++ b/ui/modules/infrastructure/infrastructure.js @@ -40,7 +40,17 @@ state: state }); }); + }, + + resource: function(args) { + var type = args.type; + + if (type) { + return cloudStack.sections.system.subsections[type]; + } else { + return false; + } } }); }; -}(jQuery, cloudStack)); \ No newline at end of file +}(jQuery, cloudStack));