index 22f06d12bd5696333de36faf50de385731164a5d..4c04e5a0e8ee1476b70b3e62a259474d5d1e30bc 100644 (file)
/* Create mail object on demand */
if (!isset($_SESSION['environment']) || (isset($_GET['reset']) && $_GET['reset'] == 1)){
$_SESSION['environment']= new environment ($config, $ui->dn);
+ $_SESSION['environment']->set_acl_category('users');
}
$environment= $_SESSION['environment'];
$_SESSION['edit']= TRUE;
}
- /* Adjust acl's to mode */
- if (isset($_SESSION['edit'])){
- $acl= get_permissions ($ui->dn, $ui->subtreeACL);
- $environment->acl= get_module_permission($acl, "gotoEnvironment", $ui->dn);
- } else {
- $acl= get_permissions ($ui->dn, $ui->subtreeACL);
- $editacl= get_module_permission($acl, "gotoEnvironment",$ui->dn);
- $environment->acl= "#none#";
- }
-
/* save changes to LDAP and disable edit mode */
if (isset($_POST['edit_finish'])){
/* Are we in edit mode? */
if ((isset($_SESSION['edit']))&&($environment->dialog==NULL)){
- $display.= "<input type=submit name=\"edit_finish\" value=\""._("Finish")."\">\n";
+ $display.= "<input type=submit name=\"edit_finish\" style=\"width:80px\" value=\""._("Ok")."\">\n";
$display.= " ";
$display.= "<input type=submit name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
$info= "<img alt=\"\" align=\"middle\" src=\"".get_template_path('images/closedlock.png').
} else {
$info= "<img alt=\"\" align=\"middle\" src=\"".get_template_path('images/openlock.png').
"\"> ".$ui->dn." ";
- if (isset($editacl) && $editacl != "#none#"){
+ # if (isset($editacl) && $editacl != "#none#"){
+ echo "FIxme, only display edit button if there is at least one attribute writeable";
$info.= "<img alt=\"\" align=\"middle\" src=\"".get_template_path('images/lamp.png').
"\"> "._("Click the 'Edit' button below to change informations in this dialog");
$display.= "<input type=submit name=\"edit\" value=\""._("Edit")."\">\n";
- }
+ # }
$display.= "<input type=\"hidden\" name=\"ignore\">\n";
}