Filter für Person oder Service-Account erstellt, Spalte externe mail eingeblendet

This commit is contained in:
Michael Dollinger 2021-01-23 12:23:06 +01:00
parent 4fe0bec4ae
commit af8cab1b94

View File

@ -5,11 +5,28 @@
<!DOCTYPE html>
<html lang="{language}">
<jsp:include page="template/header.jsp"/>
<script type="text/javascript">
function toggle(class1, class1display, class2, class2display) {
toggleRows(class1, class1display);
toggleRows(class2, class2display);
}
function toggleRows(classToToggle, style) {
var titles = document.querySelectorAll("." + classToToggle);
var i = titles.length;
while (i--) {
titles[i].setAttribute("style", style);
}
}
</script>
<body>
<jsp:include page="template/navbar.jsp"/>
<div class="container">
<h1><fmt:message key="users.title"/></h1>
<div class="control-group">
<a class="btn" onclick="toggle('type_person', '', 'type_service', 'display:none')">Only Persons</a>
<a class="btn" onclick="toggle('type_person', 'display:none', 'type_service', '')">Only Service-Accounts</a>
<a class="btn" onclick="toggle('type_person', '', 'type_service', '');">Show all</a>
<c:url var="newuserurl" value="/user/?op=create" />
<a href="${newuserurl}" class="btn btn-default pull-right additional-space-bottom"><fmt:message key="users.create"/></a>
</div>
@ -18,16 +35,22 @@
<th><fmt:message key="users.column.login"/></th>
<th><fmt:message key="users.column.firstname"/></th>
<th><fmt:message key="users.column.lastname"/></th>
<th>External mail</th>
<th colspan="2"><fmt:message key="users.column.groups"/></th>
<th><fmt:message key="users.column.operations"/></th>
</tr>
<c:forEach items="${users}" var="userentry">
<tr>
<c:url var="type_class" value="type_person"/>
<c:if test="${ !userentry.value.login.contains('.') }">
<c:url var="type_class" value="type_service"/>
</c:if>
<tr class="${type_class}">
<c:url var="upduserurl" value="/user/${userentry.key}?op=edit"/>
<td><a href="${upduserurl}">${userentry.value.login}</a></td>
<td>${userentry.value.firstname}</td>
<td>${userentry.value.lastname}</td>
<td>${userentry.value.emailExternal}</td>
<td>
<c:forEach items="${userentry.value.groups}" var="groupdn">