Code

Updated goto plugins to hide gosa-si actions until the gosaSupportURI is defined.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 12 Jan 2012 09:49:10 +0000 (09:49 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 12 Jan 2012 09:49:10 +0000 (09:49 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6@21100 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/goto/admin/systems/goto/class_terminalGeneric.inc
gosa-plugins/goto/admin/systems/goto/class_workstationGeneric.inc
gosa-plugins/goto/admin/systems/goto/terminal.tpl
gosa-plugins/goto/admin/systems/goto/workstation.tpl

index be20302d1747639d5b8f47f2223df716dc1aea95..3290572e46532487f266f611411e3879ba2f8f18 100644 (file)
@@ -294,6 +294,9 @@ class termgeneric extends plugin
     $smarty->assign("ntpservers",     $tmp);
     $smarty->assign("fai_activated",$this->fai_activated);
 
+    $si_url = $this->config->get_cfg_value("gosaSupportURI");
+    $smarty->assign("si_activated",!empty($si_url));
+
     /* Variables */
     foreach(array("gotoMode", "gotoTerminalPath", "gotoSwapServer","gotoSyslogServer", "gotoNtpServer") as $val){
       $smarty->assign($val."_select", $this->$val);
index 0a373ce8ec550d20636b8c4940e272ed070d8a65..1c23d3da604aaf39d9f087768bfba79071dede4c 100644 (file)
@@ -297,6 +297,9 @@ class workgeneric extends plugin
     $smarty->assign("syslogservers", $this->gotoSyslogServers);
     $smarty->assign("fai_activated",$this->fai_activated);
 
+    $si_url = $this->config->get_cfg_value("gosaSupportURI");
+    $smarty->assign("si_activated",!empty($si_url));
+
     $ntpser = array();
     foreach($this->gotoNtpServers as $server){
       if(!in_array_strict($server,$this->gotoNtpServer)){
index d5e6e81e2a0d08d0560479a66df9a867c33a2ed3..8e15dd4156d30a99ee7eb8b18dee18a3cbd27fc6 100644 (file)
 <table width="100%">
        <tr>
                <td style="width:50%; border-right:1px solid #AAA">
-               {if $fai_activated}
+               {if $fai_activated && $si_activated}
                        <h2><img class="center" alt="" align="middle" src="images/rocket.png"> {t}Action{/t}</h2>
                                <table summary="">
                                        <tr>
index 8e9a099972f26c039d800509d986a686b1aac2fc..55cf69567529eadfcdd5f2978af603128343e27a 100644 (file)
 {/if}
 <p class="plugbottom" style="margin-bottom:0px; padding:0px;">&nbsp;</p>
 
-{if $fai_activated}
+{if $fai_activated && $si_activated}
 <h2><img class="center" alt="" align="middle" src="images/rocket.png"> {t}Action{/t}</h2>
 <table width="100%">
 <tr><td style="border-right:1px solid #AAA; width:50%">