Code

Updated table summary
[gosa.git] / gosa-plugins / goto / addons / goto / deploy-list.tpl
index c12f6bb80b685615decc752f54f18a0acd3787f6..fc3993d2c508cbf8a949fd4e7bd820b610a1b280 100644 (file)
@@ -1,16 +1,17 @@
-<input type='image' src='images/empty.png' name='no_action_posted' value='do_nothing' alt='' style='width:2px;height:2px;'>
+<table style='width:100%;height:100%; ' summary="{t}List of running and planed goto actions{/t}">
 
-<table summary="" style="width:100%;height:100%; vertical-align:top; text-align:left;" cellpadding=2>
   <tr>
-    <td style="vertical-align:top; width:100%;">
+    <td style='width:100%;'>
+
       <div class="contentboxh">
         <p class="contentboxh">&nbsp;{$HEADLINE}&nbsp;{$SIZELIMIT}</p>
       </div>
       
       <div class="contentboxb">
        <div style='background:white;padding:3px;'>
-        <table><tr>
-          <td>{$ROOT}&nbsp;</td><td>{$BACK}&nbsp;</td><td>{$HOME}&nbsp;</td><td>{$RELOAD}&nbsp;</td><td>{$SEPARATOR}&nbsp;</td><td>{t}Base{/t} {$BASE}&nbsp;</td><td>{$SEPARATOR}&nbsp;</td><td><img src='images/rocket.png' alt='' class='center'></td><td> {$ACTIONS}</td>
+        <table summary="{$HEADLINE}"><tr>
+          <td>{$ROOT}&nbsp;</td><td>{$BACK}&nbsp;</td><td>{$HOME}&nbsp;</td><td>{$RELOAD}&nbsp;</td><td>{$SEPARATOR}&nbsp;</td><td>{t}Base{/t} {$BASE}&nbsp;</td><td>{$SEPARATOR}&nbsp;</td><td>{image path="images/rocket.png"}
+</td><td> {$ACTIONS}</td>
         </tr></table>
        </div>
       </div>
@@ -66,18 +67,17 @@ function loadContent()
        /* Create array of available progress images once 
         */
        if(!fai_status.length){
-               for (var i = 0; i < document.images.length; i++) {
-                       var img = document.images[i];
-                       var id  = img.id;
-                       if(id.match(/^progress_/)){
-                               var mac = id.replace(/^progress_/,''); 
-                               mac = mac.replace(/_/g,':'); 
-                               fai_status[c] = new Object();
-                               fai_status[c]['MAC']  = mac;
-                               fai_status[c]['PROGRESS'] = -1;
-                               c ++;
-                       }
-               }
+                var progressBars= Form.getElements("mainform");
+                progressBars.each(function(progressBar) {
+                        if(progressBar.id.match(/^progress_/)){
+                                var mac = id.replace(/^progress_/,'');
+                                mac = mac.replace(/_/g,':');
+                                fai_status[c] = new Object();
+                                fai_status[c]['MAC']  = mac;
+                                fai_status[c]['PROGRESS'] = -1;
+                                c ++;
+                        }
+                }
        }
 
        /* Create string of macs used as parameter for getFAIstatus.php
@@ -115,16 +115,13 @@ function handleContent()
                           mac and progress value */
                        var found       = false;
 
-                       /* Create object id out of mac address 
-               12:34:56:12:34:56 => progress_12_34_56_12_34_56
-             */
+                       /* Create object id out of mac address 12:34:56:12:34:56 => progress_12_34_56_12_34_56 */
                        var id          = fai_status[e]["MAC"].replace(/:/g,"_"); 
                        id = "progress_" + id;
-                       var img = document.getElementById(id);  
+                       var progressBar = document.getElementById(id);
 
-                       /* Continue if there is no image object iwth this id 
-                    */
-                       if(!img){
+                       /* Continue if there is no image object iwth this id */
+                       if(!progressBar){
                                continue;
                        }
 
@@ -140,8 +137,15 @@ function handleContent()
                                        /* Check if progress has changed 
                                         */     
                                        if(fai_status[e]["PROGRESS"] != progress){
-                                               img.src = "progress.php?x=80&y=13&p=" + progress; 
-                                               fai_status[e]["PROGRESS"] = progress;
+                                                var woffset= Math.floor(0.85 * (100-progress));
+
+                                                progressBar.setStyle({
+                                                   -moz-box-shadow: "0 0 2px rgba(255, 255, 255, 0.4) inset, 0 4px 6px rgba(255, 255, 255, 0.4) inset, 0 10px 0 -2px rgba(255, 255, 255, 0.2) inset, -" + woffset + "px 0 0 -2px rgba(255, 255, 255, 0.2) inset, -" + (woffset+1) + "px 0 0 -2px rgba(0, 0, 0, 0.6) inset, 0pt 11px 8px rgba(0, 0, 0, 0.3) inset, 0pt 1px 0px rgba(0, 0, 0, 0.2)",
+                                                   -webkit-box-shadow: "0 0 2px rgba(255, 255, 255, 0.4) inset, 0 4px 6px rgba(255, 255, 255, 0.4) inset, 0 10px 0 -2px rgba(255, 255, 255, 0.2) inset, -" + woffset + "px 0 0 -2px rgba(255, 255, 255, 0.2) inset, -" + (woffset+1) + "px 0 0 -2px rgba(0, 0, 0, 0.6) inset, 0pt 11px 8px rgba(0, 0, 0, 0.3) inset, 0pt 1px 0px rgba(0, 0, 0, 0.2)",
+                                                   box-shadow: "0 0 2px rgba(255, 255, 255, 0.4) inset, 0 4px 6px rgba(255, 255, 255, 0.4) inset, 0 10px 0 -2px rgba(255, 255, 255, 0.2) inset, -" + woffset + "px 0 0 -2px rgba(255, 255, 255, 0.2) inset, -" + (woffset+1) + "px 0 0 -2px rgba(0, 0, 0, 0.6) inset, 0pt 11px 8px rgba(0, 0, 0, 0.3) inset, 0pt 1px 0px rgba(0, 0, 0, 0.2)"
+                                                });
+                                                fai_status[e]["PROGRESS"] = progress;
+
                                        }
                                        break;
                                }