X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;ds=sidebyside;f=gosa-plugins%2Fsudo%2Fadmin%2Fsudo%2Fclass_divListSudo.inc;h=3a33cec20b854ee6195e54f70c2309869055eb4c;hb=5d35094663a14290dc22c8520501f75889aeff5b;hp=de03718668d44ad923186b0dbfee5554e2933ef8;hpb=f709bb1bb89176ef38706971dd86214504795f27;p=gosa.git
diff --git a/gosa-plugins/sudo/admin/sudo/class_divListSudo.inc b/gosa-plugins/sudo/admin/sudo/class_divListSudo.inc
index de0371866..3a33cec20 100644
--- a/gosa-plugins/sudo/admin/sudo/class_divListSudo.inc
+++ b/gosa-plugins/sudo/admin/sudo/class_divListSudo.inc
@@ -28,17 +28,16 @@ class divListSudo extends MultiSelectWindow
{
/* Current base */
- var $selectedBase = "";
- var $departments = array();
+ private $departments = array();
/* Regex */
- var $Regex = "*";
- var $UserRegex = "*";
+ public $Regex = "*";
+ public $UserRegex = "*";
/* Subsearch checkbox */
- var $SubSearch = FALSE;
- var $parent ;
- var $ui ;
+ public $SubSearch = FALSE;
+ protected $parent ;
+ public $ui ;
/*! \brief Initialize this class
@@ -65,9 +64,12 @@ class divListSudo extends MultiSelectWindow
$this->EnableSaveButton (false);
/* Dynamic action col, depending on snapshot icons */
- $action_col_size = 50;
+ $action_col_size = 54;
if($this->parent->snapshotEnabled()){
- $action_col_size += 38;
+ $action_col_size += 32;
+ }
+ if($this->parent->CopyPasteHandler){
+ $action_col_size += 20;
}
/* Toggle all selected / deselected */
@@ -120,6 +122,24 @@ class divListSudo extends MultiSelectWindow
" "._("Remove")."|"."del_role|\n";
}
+ /* Add multiple copy & cut icons */
+ if(is_object($this->parent->CopyPasteHandler) && preg_match("/(c.*w|w.*c)/",$acl)){
+ $s.= "..|---|\n";
+ $s.= "..|
".
+ " "._("Copy")."|"."multiple_copy_sudo|\n";
+# $s.= "..|
".
+# " "._("Cut")."|"."multiple_cut_sudo|\n";
+
+ if($this->parent->CopyPasteHandler->entries_queued()){
+ $img = "
";
+ $s.="..|".$img." "._("Paste")."|editPaste|\n";
+ }else{
+ $img = "
";
+ $s.="..|".$img." "._("Paste")."\n";
+ }
+ }
+
+
/* Add snapshot icons */
if(preg_match("/(c.*w|w.*c)/",$acl)){
$s .= "..|---|\n";
@@ -151,9 +171,12 @@ class divListSudo extends MultiSelectWindow
$userimg = "
";
$ui = get_userinfo();
- $action_col_size = 50;
+ $action_col_size = 54;
if($this->parent->snapshotEnabled()){
- $action_col_size += 38;
+ $action_col_size += 32;
+ }
+ if($this->parent->CopyPasteHandler){
+ $action_col_size += 20;
}
// Test Every Entry and generate divlist Array
@@ -164,6 +187,16 @@ class divListSudo extends MultiSelectWindow
/* Add edit icon */
$actions = "";
+
+ $actions= "";
+ if(($this->parent->CopyPasteHandler) && preg_match("/(c.*w|w.*c)/",$acl)){
+# $actions.= " ";
+ $actions.= " ";
+ }
+
+
$actions.= "";
@@ -191,6 +224,16 @@ class divListSudo extends MultiSelectWindow
$display = "$display";
}
+ /* Cutted objects should be displayed in light grey */
+ if($this->parent->CopyPasteHandler){
+ foreach($this->parent->CopyPasteHandler->queue as $queue_key => $queue_data){
+ if($queue_data['dn'] == $val['dn']) {
+ $display = "".$display."";
+ break;
+ }
+ }
+ }
+
$field1 = array("string" => "" ,
"attach" => "style='width:20px;'");
$field2 = array("string" => sprintf($userimg,$val['dn']),