You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by pr...@apache.org on 2013/05/31 06:36:06 UTC
[16/25] git commit: updated refs/heads/master to 2f29185
explicit Dedication - Pod action filter for release/dedicate action items
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/1c9a34ab
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/1c9a34ab
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/1c9a34ab
Branch: refs/heads/master
Commit: 1c9a34abccdbd14d00b5fe6f4bb64f6fed1ef2d1
Parents: fd72c12
Author: Pranav Saxena <pr...@citrix.com>
Authored: Tue May 28 16:00:24 2013 +0530
Committer: Pranav Saxena <pr...@citrix.com>
Committed: Thu May 30 21:57:14 2013 +0530
----------------------------------------------------------------------
ui/scripts/system.js | 15 ++++++++++++++-
1 files changed, 14 insertions(+), 1 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1c9a34ab/ui/scripts/system.js
----------------------------------------------------------------------
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index c68def0..933f271 100644
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -12763,8 +12763,21 @@
var podActionfilter = function(args) {
var podObj = args.context.item;
var allowedActions = [];
+
+ $.ajax({
+ url:createURL("listDedicatedPods&podId=" + args.context.pods[0].id),
+ success:function(json){
+ if(json.listdedicatedpodsresponse.dedicatedpod != undefined){
+ var dedicatedPodObj = json.listdedicatedpodsresponse.dedicatedpod[0];
+ if(dedicatedPodObj.domainid != null)
+ allowedActions.push("release");
+ }
+ else
+ allowedActions.push("dedicate");
+ }
+ });
+
allowedActions.push("edit");
- allowedActions.push("dedicate");
if(podObj.allocationstate == "Disabled")
allowedActions.push("enable");
else if(podObj.allocationstate == "Enabled")