From 7adadd4a5873966dcbbf24d8446d38df6c794c37 Mon Sep 17 00:00:00 2001 From: hickert Date: Fri, 7 Dec 2007 13:57:42 +0000 Subject: [PATCH] Updated locking for multiple edit git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8060 594d385d-05f5-0310-b6e9-bd551577e9d8 --- include/class_multi_plug.inc | 15 ++++++++++++--- plugins/admin/users/class_userManagement.inc | 2 +- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/include/class_multi_plug.inc b/include/class_multi_plug.inc index e1bd7ce8f..b0b6abdb6 100644 --- a/include/class_multi_plug.inc +++ b/include/class_multi_plug.inc @@ -126,6 +126,12 @@ class multi_plug */ public function entries_locked() { + $ui = get_userinfo(); + foreach($this->dn as $dn){ + if(get_lock($dn) != ""){ + return(TRUE); + } + } return(FALSE); } @@ -135,7 +141,10 @@ class multi_plug */ public function display_lock_message() { - return("sdf"); + $ui = get_userinfo(); + $lock_msg = ""; + $lock_msg.= gen_locked_message ($ui->dn, $this->dn); + return($lock_msg); } @@ -170,7 +179,7 @@ class multi_plug */ public function get_object_info() { - return("Oi -----"); + return(_("You are currently editing mutliple entries.")); } @@ -234,7 +243,7 @@ class multi_plug if($this->multiple_available() && is_array($this->a_handles)){ $this->populate_values(); foreach($this->a_handles as $i_id => $o_handle){ - $o_handle->save(TRUE); + $o_handle->save(); } } } diff --git a/plugins/admin/users/class_userManagement.inc b/plugins/admin/users/class_userManagement.inc index a2f6f70a2..a031e89d9 100644 --- a/plugins/admin/users/class_userManagement.inc +++ b/plugins/admin/users/class_userManagement.inc @@ -62,7 +62,7 @@ class userManagement extends plugin plugin::execute(); /* LOCK MESSAGE Vars */ - $_SESSION['LOCK_VARS_TO_USE'] = array("/^act$/","/^id$/","/^user_edit_/","/^user_del_/","/^item_selected/","/^remove_multiple_users/","/^multiple_edit/"); + $_SESSION['LOCK_VARS_TO_USE'] = array("/^act$/","/^id$/","/^user_edit_/","/^user_del_/","/^item_selected/","/^remove_multiple_users/","/^multiple_edit/","/menu_action/"); $smarty = get_smarty(); // Smarty instance $s_action = ""; // Contains the action to be taken -- 2.30.2