Code

Added base select icon to systems
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 28 Feb 2006 05:31:48 +0000 (05:31 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 28 Feb 2006 05:31:48 +0000 (05:31 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2753 594d385d-05f5-0310-b6e9-bd551577e9d8

14 files changed:
plugins/admin/systems/class_componentGeneric.inc
plugins/admin/systems/class_phoneGeneric.inc
plugins/admin/systems/class_printGeneric.inc
plugins/admin/systems/class_servGeneric.inc
plugins/admin/systems/class_terminalGeneric.inc
plugins/admin/systems/class_winGeneric.inc
plugins/admin/systems/class_workstationGeneric.inc
plugins/admin/systems/component.tpl
plugins/admin/systems/phone.tpl
plugins/admin/systems/printer.tpl
plugins/admin/systems/server.tpl
plugins/admin/systems/terminal.tpl
plugins/admin/systems/wingeneric.tpl
plugins/admin/systems/workstation.tpl

index 250261b2c7e7b6a4b9a0a76162f3249ac240133c..23c2428557f844e0adb633702645b2e72808b3c8 100644 (file)
@@ -51,6 +51,31 @@ class componentGeneric extends plugin
       return($display);
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
+
     /* Fill templating stuff */
     $smarty= get_smarty();
     $smarty->assign("bases", $this->config->idepartments);
index ee1916c5803aa7a7187e8dfc07b804a70509cf27..863e7c3d94a0dea690123d1bef6ff8b2a8c4dd7e 100644 (file)
@@ -106,6 +106,31 @@ class phoneGeneric extends plugin
       return($display);
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
+
     /* handle Permit Add*/
     if(isset($_POST['goFonPermitAdd'])){
       if(isset($_POST['goFonPermitNew'])){
index ed47351eaf4726ca610532ebf4b3d7463cec06d3..6870431ba8cc71cb14c0b58a9adec9a3925df943 100644 (file)
@@ -246,6 +246,30 @@ class printgeneric extends plugin
       }
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
 
     /* Do we represent a valid printer? */
     if (!$this->is_account && $this->parent == NULL){
index 9252d16a969a181f0935a791947f6c4aee1069a5..62a31192ac8456635f9498c1e2a3cc4228310997 100644 (file)
@@ -94,6 +94,31 @@ class servgeneric extends plugin
       }
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
+
     /* Fill templating stuff */
     $smarty= get_smarty();
     $smarty->assign("bases", $this->config->idepartments);
index 75556b63ddd9e4f04f3ad60366c5054d6b2d5a40..8b252d8f0baa4e5e98ab0139476d633b5043bedf 100644 (file)
@@ -122,6 +122,31 @@ class termgeneric extends plugin
       }
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
+
     /* Do we represent a valid terminal? */
     if (!$this->is_account && $this->parent == NULL){
       $display= "<img alt=\"\" src=\"images/stop.png\" align=middle>&nbsp;<b>".
index 089c096ac955be2fca4c46c40a991efbd500742f..5f250619cd9212478bb2eca9c44325eef0574dc6 100644 (file)
@@ -74,6 +74,31 @@ class wingeneric extends plugin
       return($display);
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
+
     /* Fill templating stuff */
     $smarty= get_smarty();
 
index f34e55a8c41dea7e1c8a38cbf6fcafe8e5e3d7dd..f4104e0971ca68abbede37602a91ef278874e9e7 100644 (file)
@@ -115,6 +115,31 @@ class workgeneric extends plugin
       return($display);
     }
 
+    /* Base select dialog */
+    $once = true;
+    foreach($_POST as $name => $value){
+      if(preg_match("/^chooseBase/",$name) && $once){
+        $once = false;
+        $this->dialog = new baseSelectDialog($this->config);
+        $this->dialog->setCurrentBase($this->base);
+      }
+    }
+
+    /* Dialog handling */
+    if(is_object($this->dialog)){
+      /* Must be called before save_object */
+      $this->dialog->save_object();
+
+      if($this->dialog->isClosed()){
+        $this->dialog = false;
+      }elseif($this->dialog->isSelected()){
+        $this->base = $this->dialog->isSelected();
+        $this->dialog= false;
+      }else{
+        return($this->dialog->execute());
+      }
+    }
+
     /* Fill templating stuff */
     $smarty= get_smarty();
     $smarty->assign("cn", $this->cn);
index a1581c2d5850f6877e63920675d5b8ef2a685530..2b27b6aa471438e336c15364a87477b4c588653f 100644 (file)
@@ -15,6 +15,7 @@
           <select size="1" id="base" name="base" title="{t}Choose subtree to place terminal in{/t}">
            {html_options options=$bases selected=$base_select}
           </select>
+               <input type="image" name="chooseBase" src="images/folder.png" class="center">
          </tr>
        </table>
   </td>
index f08591542a084afce61f9dc343bb5204248c5daf..c640f8c1ccbe8524072808dc115bb35d837148e0 100644 (file)
@@ -14,7 +14,8 @@
          <td>
           <select size="1" id="base" name="base" title="{t}Choose subtree to place terminal in{/t}">
            {html_options options=$bases selected=$base_select}
-          </select>
+          </select>    
+               <input type="image" name="chooseBase" src="images/folder.png" class="center">
          </tr>
        </table>
   </td>
index 37b42402fd5384de569e385c6c35502e57521091..8379bfe48e0fae3b21f2e0879577d4013c82615e 100644 (file)
@@ -22,6 +22,7 @@
                           <select size="1" name="base" title="{t}Choose subtree to place terminal in{/t}">
                                {html_options options=$bases selected=$base_select}
                           </select>
+                               <input type="image" name="chooseBase" src="images/folder.png" class="center">
                          </tr>
                        </table>
                </td>
index fe84f853c9859706f00b8ef12e9f36f17074adaf..e3ce344fbbc9379078aaeba18b9411f0d681c9db 100644 (file)
@@ -15,6 +15,7 @@
           <select size="1" name="base" id="base" title="{t}Choose subtree to place terminal in{/t}">
            {html_options options=$bases selected=$base_select}
           </select>
+               <input type="image" name="chooseBase" src="images/folder.png" class="center">
          </tr>
        </table>
   </td>
index 2da3738a63e7e68d2a0ddd594ee2938afd43ac56..5827b7df28bd199199b1b790ac7e6efea25a7d96 100644 (file)
@@ -20,6 +20,7 @@
       <select size="1" id="base" name="base" title="{t}Choose subtree to place terminal in{/t}">
        {html_options options=$bases selected=$base_select}
       </select>
+               <input type="image" name="chooseBase" src="images/folder.png" class="center">
     </tr>
    </table>
 
index d7f69b66bfe8028f0b6ba37420b7813a08551ac6..666b320163a5249d1fc13605d058a5a4530424a6 100644 (file)
@@ -15,6 +15,7 @@
           <select size="1" id="base" name="base" title="{t}Choose subtree to place terminal in{/t}">
            {html_options options=$bases selected=$base_select}
           </select>
+               <input type="image" name="chooseBase" src="images/folder.png" class="center">
          </tr>
        </table>
   </td>
index d278f53140edc6febda01107a8805532fddc1aff..e1016ea7d687a52df56a1fc21c160c5acbb82cf6 100644 (file)
@@ -29,6 +29,7 @@
       <select size="1" id="base" name="base" title="{t}Choose subtree to place terminal in{/t}">
        {html_options options=$bases selected=$base_select}
       </select>
+               <input type="image" name="chooseBase" src="images/folder.png" class="center">
     </tr>
    </table>