summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ebdc695)
raw | patch | inline | side by side (parent: ebdc695)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 28 Aug 2006 10:15:44 +0000 (10:15 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 28 Aug 2006 10:15:44 +0000 (10:15 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4524 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_MultiSelectWindow.inc | patch | blob | history | |
plugins/admin/users/class_divListUsers.inc | patch | blob | history |
index 60b11f168fd7b396ff3f2ccabf7bb2a0d3e7ba43..bbba65eeeaf44d469bd63722a0e49c08779e8171 100644 (file)
$str = "<img class='center' src='images/restore_grey.png' alt=''> ";
}
- $str .= "<img class='center' src='images/list_seperator.png' align='middle' alt='' height='16' width='1'> ";
+# $str .= "<img class='center' src='images/list_seperator.png' align='middle' alt='' height='16' width='1'> ";
}
return($str);
}
diff --git a/plugins/admin/users/class_divListUsers.inc b/plugins/admin/users/class_divListUsers.inc
index d239375b8c7c9ed2a457f5a2c0ff10b298a6dd1e..e06517ca3db79757747b6a8e70666f23d98e1d64 100644 (file)
}
/* Get copy & paste icon */
- if($this->parent->CopyPasteHandler){
+ if(preg_match("/w/",$ui->get_permissions($this->selectedBase,"users/user")) && $this->parent->CopyPasteHandler){
$Copy_Paste = $this->parent->CopyPasteHandler->generatePasteIcon();
}else{
$Copy_Paste ="";
title='"._("Reload list")."' name='submit_department' alt='"._("Submit")."'> ".
" <img class='center' src='images/list_seperator.png' align='middle' alt='-' height='16' width='1'> ";
$listhead .= $this->get_snapshot_header($this->selectedBase);
- $listhead .= " <input class='center' type='image' align='middle' src='images/list_new_user.png'
- title='"._("Create new user")."' alt='"._("New user")."' name='user_new'> ".
- " <input class='center' type='image' align='middle' src='images/list_new.png'
- title='"._("Create new template")."' alt='"._("New template")."' name='user_tplnew'> ".
+
+ $acls = $ui->get_permissions($this->selectedBase,"users/user");
+ if(preg_match("/c/",$acls)) {
+ $listhead .= " <input class='center' type='image' align='middle' src='images/list_new_user.png'
+ title='"._("Create new user")."' alt='"._("New user")."' name='user_new'> ";
+ $listhead .= " <input class='center' type='image' align='middle' src='images/list_new.png'
+ title='"._("Create new template")."' alt='"._("New template")."' name='user_tplnew'> ";
+# $listhead .= " <img class='center' src='images/list_seperator.png' align='middle' alt='-' height='16' width='1'> ";
+ }
+
+ $listhead .=
$Copy_Paste.
- " <img class='center' src='images/list_seperator.png' align='middle' alt='-' height='16' width='1'> ".
_("Base")." <select name='CurrentMainBase' onChange='mainform.submit()' class='center'>$options</select>".
" <input class='center' type='image' src='images/list_submit.png' align='middle'
title='"._("Submit department")."' name='submit_department' alt='". _("Submit")."'> ".
Append entries to divlist
********************/
+ $ui = get_userinfo();
+
// Test Every Entry and generate divlist Array
foreach($list as $key => $val){
/* Create action icons */
$action= "";
- if($this->parent->CopyPasteHandler){
+
+ /* Add copy & cut icons */
+ if($this->parent->CopyPasteHandler && preg_match("/w/",$ui->get_category_permissions($val['dn'],"users"))) {
$action .= "<input class='center' type='image'
src='images/editcut.png' alt='"._("cut")."' name='cut_%KEY%' title='"._("Cut this entry")."'> ";
$action.= "<input class='center' type='image'
src='images/editcopy.png' alt='"._("copy")."' name='copy_%KEY%' title='"._("Copy this entry")."'> ";
}
+
+ /* Generate edit icon */
$action.= "<input class='center' type='image' src='images/edit.png' alt='"._("edit")."'
name='user_edit_%KEY%' title='"._("Edit user")."'>";
- $action.= "<input class='center' type='image' src='images/list_password.png' alt='"._("password")."'
- name='user_chgpw_%KEY%' title='"._("Change password")."'>";
+
+ /* Add Password change icon, if we are able to write users/password */
+ if(preg_match("/w/",$ui->get_permissions($val['dn'],"users/password"))) {
+ $action.= "<input class='center' type='image' src='images/list_password.png' alt='"._("password")."'
+ name='user_chgpw_%KEY%' title='"._("Change password")."'>";
+ }else{
+ $action.= "<img class='center' src='images/empty.png' alt=' '
+ title='"._("You are not allowed to change the password for this user.")."'>";
+ }
+
+ /* Add snapshot icon */
$action.= $this->GetSnapShotActions($val['dn']);
- $action.= "<input class='center' type='image' src='images/edittrash.png' alt='"._("delete")."'
- name='user_del_%KEY%' title='"._("Delete user")."'>";
+ /* Add remove icon, if we are allowed to remove the current user */
+ if(preg_match("/d/",$ui->get_permissions($val['dn'],"users/user"))) {
+ $action.= "<input class='center' type='image' src='images/edittrash.png' alt='"._("delete")."'
+ name='user_del_%KEY%' title='"._("Delete user")."'>";
+ }else{
+ $action.= "<img class='center' src='images/empty.png' alt=' '
+ title='"._("You are not allowed to remove this user.")."'>";
+ }
/* Create phonaccopunt informationm, if conencted && is phoneAccount */
$connected = ""; // This string represents timestamp or offline status