Beispiel #1
0
    }
    /* We display the smallest telephone number, hopefully it is the user phone extension */
    $num = null;
    foreach ($users[$idx]["telephoneNumber"] as $number) {
        if ($num == null) {
            $num = $number;
        } else {
            if (strlen($number) < strlen($num)) {
                $num = $number;
            }
        }
    }
    $phones[] = $num;
}
// $arrUser is the list of all Users
$n = new UserInfos($arrUser, _("Login"));
$n->setItemCount($usercount);
$n->setNavBar(new AjaxPaginator($usercount, $filter, "updateSearchParam", $maxperpage));
$n->start = 0;
$n->end = $usercount - 1;
$n->setCssClass("userName");
$n->css = $css;
$n->addExtraInfo($arrSnUser, _("Name"));
$n->addExtraInfo($mails, _("Mail"));
$n->addExtraInfo($phones, _("Telephone"));
$n->addActionItem(new ActionItem(_("Edit"), "edit", "edit", "user"));
if (in_array("extticket", $_SESSION["supportModList"])) {
    $n->addActionItem(new ActionItem(_("extTicket issue"), "extticketcreate", "extticket", "user"));
}
$n->addActionItem(new ActionItem(_("MMC rights"), "editacl", "editacl", "user"));
$n->addActionItem(new ActionPopupItem(_("Delete"), "delete", "delete", "user"));
Beispiel #2
0
foreach (xmlCall("base.getLdapLog", array($_SESSION['ajax']['filter'])) as $line) {
    if (is_array($line)) {
        $connectionNumber[] = '<a href="#" onClick="jQuery(\'#param\').val(\'' . 'conn=' . $line["conn"] . '\'); pushSearch(); return false">' . $line["conn"] . '</a>';
        $action[] = '<a href="#" onClick="jQuery(\'#param\').val(\'' . $line["op"] . '\'); pushSearch(); return false">' . $line["op"] . '</a>';
        $extra[] = $line["extra"];
        $dateparsed = strftime('%b %d %H:%M:%S', $line["time"]);
        $date[] = str_replace(" ", "&nbsp;", $dateparsed);
        if ($line["opfd"] == "op") {
            $oparr[] = $line["opfdnum"];
        } else {
            $oparr[] = "";
        }
    } else {
        $connectionNumber[] = "";
        $action[] = "";
        $date[] = "";
        $oparr[] = "";
        $extra[] = $line;
    }
}
$n = new UserInfos($date, _("Date"), "1px");
$n->addExtraInfo($connectionNumber, _("Connection"), "1px");
$n->addExtraInfo($oparr, _("Operation"), "1px");
$n->addExtraInfo($action, _("Actions"), "1px");
$n->addExtraInfo($extra, _("Extra information"));
$n->end = 200;
$n->first_elt_padding = 1;
$n->display(0, 0);
?>
</div>
Beispiel #3
0
/*for ($idx = $start;
  ($idx < count($users)) && ($idx <= $end);
  $idx++)*/
$css = array();
for ($idx = 0; $idx < count($users); $idx++) {
    if ($users[$idx]["enabled"]) {
        $css[$idx] = "userName";
    } else {
        $css[$idx] = "userNameDisabled";
    }
    $arrUser[] = $users[$idx]['uid'];
    $arrSnUser[] = $users[$idx]['givenName'] . ' ' . $users[$idx]['sn'];
    $homeDirArr[] = $users[$idx]['homeDirectory'];
}
// $arrUser is the list of all Users
$n = new UserInfos($arrUser, _("Login"));
$n->setCssClass("userName");
$n->css = $css;
$n->addExtraInfo($arrSnUser, _("Name"));
//add a list with all homeDir
$n->addExtraInfo($homeDirArr, _("Home directory"));
$n->addActionItem(new ActionItem(_("Edit"), "edit", "edit", "user"));
//
$n->addActionItem(new ActionItem(_("MMC rights"), "editacl", "editacl", "user"));
$n->addActionItem(new ActionPopupItem(_("Delete"), "delete", "delete", "user"));
$n->addActionItem(new ActionPopupItem(_("Backup"), "backup", "backup", "user"));
$n->setName(_("Users"));
$n->display();
?>

</div>