diff --git a/ui/scripts/system.js b/ui/scripts/system.js index 4755f270b48..42a8d3679dc 100644 --- a/ui/scripts/system.js +++ b/ui/scripts/system.js @@ -12228,8 +12228,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")