Code

Cutted objects will be displayed in light grey in the management lists now.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 7 Aug 2007 06:57:01 +0000 (06:57 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 7 Aug 2007 06:57:01 +0000 (06:57 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@6975 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/applications/class_divListApplication.inc
plugins/admin/fai/class_divListFai.inc
plugins/admin/groups/class_divListGroup.inc
plugins/admin/mimetypes/class_divListMimeTypes.inc
plugins/admin/mimetypes/class_mimetypeManagement.inc
plugins/admin/ogroups/class_divListOGroup.inc
plugins/admin/systems/class_divListSystem.inc
plugins/admin/users/class_divListUsers.inc

index 182044c7e0de70f0c4ce907d8b94e21dc4d0653a..76961f236de0fd39a3ed48fccd777cf2add92bc5 100755 (executable)
@@ -172,8 +172,15 @@ class divListApplication extends MultiSelectWindow
       }else{
         $desc = " - [ ".$val['description'][0]." ]";
       }
+
+      /* Cutted objects should be displayed in light grey */
+      $display = $val['cn']['0'].$desc;
+      if($this->parent->CopyPasteHandler->cutCurrent && $val['dn'] == $this->parent->CopyPasteHandler->objectdn){
+        $display = "<font color='#999999'>".$display."</font>";
+      }
+
       $field1 = array("string" => sprintf($applimg,$val['dn']), "attach" => "style='text-align:center;width:20px;'");
-      $field2 = array("string" => sprintf($editlink,$key,($val['cn']['0'].$desc)), "attach" => "style='' ".$title);
+      $field2 = array("string" => sprintf($editlink,$key,$display), "attach" => "style='' ".$title);
       $field3 = array("string" => preg_replace("/%KEY%/", $key, $actions), "attach" => "style='width:80px;border-right:0px;text-align:right;'");
       $this->AddElement(array($field1,$field2,$field3));
     }
index c474b15e0d9f243fab07ab67e92dd16060587807..fb87be8539407fa16aba7efde2d730da5db476c4 100644 (file)
@@ -233,14 +233,18 @@ class divListFai extends MultiSelectWindow
          $edi = $editlink;
        }
 
-
+       /* Cutted objects should be displayed in light grey */
+       $display = $value['cn'].$desc;
+       if($this->parent->CopyPasteHandler->cutCurrent && $value['dn'] == $this->parent->CopyPasteHandler->objectdn){
+         $display = "<font color='#999999'>".$display."</font>";
+       }
 
        $field1 = array("string" => $img , "attach" => "style='text-align:center;width:20px;'");
-       $field2 = array("string" => preg_replace(array("/%KEY%/","/%NAME%/","/%TITLE%/"),array($key,$value['cn'].$desc,preg_replace('/ /', '&nbsp;', @LDAP::fix($value['dn']))),$edi) , "attach" => "style=''");
+       $field2 = array("string" => preg_replace(array("/%KEY%/","/%NAME%/","/%TITLE%/"),array($key,$display,preg_replace('/ /', '&nbsp;', @LDAP::fix($value['dn']))),$edi) , "attach" => "style=''");
        $field3 = array("string" => $info, "attach" => "style='width:200px;'");
        $field4 = array("string" => preg_replace("/%KEY%/",$key,$acti) , "attach" => "style='width:80px;border-right:0px;text-align:right;'");
        $this->AddElement(array($field1,$field2,$field3,$field4));
-    }
+     }
   }
 
   function Save()
index 2114313da59ee6e365c363277097054315974b0e..4bc375b4343836928cfc5cafabf4809aa736665d 100644 (file)
@@ -188,8 +188,14 @@ class divListGroup extends MultiSelectWindow
         $desc .= " (".$val['FAIrelease'][0].")";
       }
 
+      /* Cutted objects should be displayed in light grey */
+      $display = $val['cn']['0'].$desc;
+      if($this->parent->CopyPasteHandler->cutCurrent && $val['dn'] == $this->parent->CopyPasteHandler->objectdn){
+        $display = "<font color='#999999'>".$display."</font>";
+      }
+
       $field1 = array("string" => sprintf($userimg,$val['dn']), "attach" => "style='text-align:center;width:20px;'");
-      $field2 = array("string" => sprintf($editlink,$key,($val['cn']['0'].$desc)), "attach" => "style='' ".$title);
+      $field2 = array("string" => sprintf($editlink,$key,$display), "attach" => "style='' ".$title);
       $field3 = array("string" => preg_replace("/%KEY%/", $key, $posix."&nbsp;".$enviro."&nbsp;".$mail."&nbsp;".$samba."&nbsp;".$appl."&nbsp;".$phone),     "attach" => "style='width:136px;'");
       $field4 = array("string" => preg_replace("/%KEY%/", $key, $actions), "attach" => "style='width:80px;border-right:0px;text-align:right;'");
 
index 92427c02f8ce5b147599371da7faa922de1e241b..61f7e0d8f3275d0ce45d7d76b4839470550f2aa3 100755 (executable)
@@ -157,8 +157,14 @@ class divListMimeTypes extends MultiSelectWindow
         $desc = " - [ ".$val['description'][0]." ]";
       }
 
+      /* Cutted objects should be displayed in light grey */
+      $display = $val['cn'][0].$desc;
+      if($this->parent->CopyPasteHandler->cutCurrent && $val['dn'] == $this->parent->CopyPasteHandler->objectdn){
+        $display = "<font color='#999999'>".$display."</font>";
+      }
+
       $field1 = array("string" => sprintf($mimeimg,$val['dn']), "attach" => "style='text-align:center;width:20px;'");
-      $field2 = array("string" => sprintf($editlink,$key,($val['cn']['0'].$desc)), "attach" => "style='' ".$title);
+      $field2 = array("string" => sprintf($editlink,$key,$display), "attach" => "style='' ".$title);
       $field3 = array("string" => preg_replace("/%KEY%/", $key, $actions), "attach" => "style='width:".$action_col_size."px;border-right:0px;text-align:right;'");
       $this->AddElement(array($field1,$field2,$field3));
     }
index f9a58748f28b698e4c515a39bbc00f352c161d6d..f4553fe7057d838ff7cdc5c359e6e4b25e972612 100755 (executable)
@@ -534,9 +534,9 @@ class mimetypeManagement extends plugin
     }
 
     /* Automatically disable status for pasting */
-    if(!$this->CopyPasteHandler->entries_queued()){
-      $this->start_pasting_copied_objects = FALSE;
-    }
+    #if(!$this->CopyPasteHandler->entries_queued()){
+    #  $this->start_pasting_copied_objects = FALSE;
+    #}
     return("");
   }
 
index 7dccc31ac9b71fc09e68b29232c7eb712a819cea..da2021de3aceaf034b39333348a8d12e96939e81 100755 (executable)
@@ -157,8 +157,15 @@ class divListOGroup extends MultiSelectWindow
       }else{
         $desc = " - [ ".$val['description'][0]." ]";
       }
+
+      /* Cutted objects should be displayed in light grey */
+      $display = $val['cn'][0].$desc;
+      if($this->parent->CopyPasteHandler->cutCurrent && $val['dn'] == $this->parent->CopyPasteHandler->objectdn){
+        $display = "<font color='#999999'>".$display."</font>";
+      }
+
       $field1 = array("string" => "<img src='images/list_ogroup.png' alt='"._("Object group")."' ".$title.">", "attach" => "style='text-align:center;width: 20px;'");
-      $field2 = array("string" => sprintf($editlink,$key,($val['cn']['0'].$desc)), "attach" => "style='' ".$title);
+      $field2 = array("string" => sprintf($editlink,$key,$display), "attach" => "style='' ".$title);
       $field3 = array("string" => preg_replace("/%KEY/", $key, $this->parent->convert_list($val))."&nbsp;".$mail, "attach" => "style='width:136px;'");
       $field4 = array("string" => preg_replace("/%KEY%/", $key, $actions), "attach" => "style='width:107px;border-right:0px;text-align:right;'");
 
index c98116dd11c42da09fd851b668e3b9c734e3c183..7e46fa959cb39dabf776a551ad0dab03797348cc 100644 (file)
@@ -189,6 +189,11 @@ class divListSystem extends MultiSelectWindow
         $display.= "  (".$val['message'].")";
       }
 
+      /* Cutted objects should be displayed in light grey */
+      if(isset($this->parent->CopyPasteHandler) && $this->parent->CopyPasteHandler->cutCurrent && $val['dn'] == $this->parent->CopyPasteHandler->objectdn){
+        $display = "<font color='#999999'>".$display."</font>";
+      }
+
       $img    = $this->parent->convert_list($val);
       $field1 = array("string" => sprintf($img['img'],$val['dn']), "attach" => "style='text-align:center;width:20px;'");
       $field2 = array("string" => sprintf($editlink,$key,$display), "attach" => "style='' title='".preg_replace('/ /', '&nbsp;', @LDAP::fix($val['dn']))."'");
index 7e749f15f84c8d41139667df07a8a61647fda42e..ae49cc080b56e5e88382e1c2430060d29f483c14 100644 (file)
@@ -239,6 +239,11 @@ class divListUsers extends MultiSelectWindow
       /* Connect all images */
       $UseImg = $usrimg2."&nbsp;".$posix."&nbsp;".$enviro."&nbsp;".$maila."&nbsp;".$fonac."&nbsp;".$faxac."&nbsp;".$samba."&nbsp;".$netatalk;
 
+      /* Cutted objects should be displayed in light grey */ 
+      if($this->parent->CopyPasteHandler->cutCurrent && $val['dn'] == $this->parent->CopyPasteHandler->objectdn){
+        $display = "<font color='#999999'>".$display."</font>";
+      }
+
       /* Create each field */
       $field1 = array("string" => sprintf($tpl,$val['dn']), "attach" => "style='text-align:center;width:20px;'");
       $field2 = array("string" => sprintf($editlink,$key,$display), "attach" => "style='' title='".preg_replace('/ /', '&nbsp;', @LDAP::fix($val['dn']))."'");