1.1 --- a/src/main/webapp/WEB-INF/jsp/project-navmenu.jsp Sat Jan 23 14:47:59 2021 +0100 1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 1.3 @@ -1,104 +0,0 @@ 1.4 -<%-- 1.5 -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 1.6 - 1.7 -Copyright 2021 Mike Becker. All rights reserved. 1.8 - 1.9 -Redistribution and use in source and binary forms, with or without 1.10 -modification, are permitted provided that the following conditions are met: 1.11 - 1.12 -1. Redistributions of source code must retain the above copyright 1.13 -notice, this list of conditions and the following disclaimer. 1.14 - 1.15 -2. Redistributions in binary form must reproduce the above copyright 1.16 -notice, this list of conditions and the following disclaimer in the 1.17 -documentation and/or other materials provided with the distribution. 1.18 - 1.19 -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 1.20 -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1.21 -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 1.22 -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 1.23 -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1.24 -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 1.25 -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 1.26 -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 1.27 -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 1.28 -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 1.29 ---%> 1.30 -<%@page pageEncoding="UTF-8" 1.31 - import="de.uapcore.lightpit.viewmodel.ProjectView" 1.32 - import="de.uapcore.lightpit.types.VersionStatus" 1.33 -%> 1.34 -<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 1.35 -<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> 1.36 - 1.37 -<jsp:useBean id="viewmodel" type="de.uapcore.lightpit.viewmodel.ProjectView" scope="request"/> 1.38 - 1.39 -<c:forEach var="projectInfo" items="${viewmodel.projectList}"> 1.40 - <c:set var="isActive" value="${viewmodel.projectInfo.project eq projectInfo.project}" /> 1.41 - <div class="menuEntry level-0" <c:if test="${isActive}">data-active</c:if> > 1.42 - <a href="projects/${projectInfo.project.node}/versions/"> 1.43 - <c:out value="${projectInfo.project.name}"/> 1.44 - </a> 1.45 - </div> 1.46 - <c:if test="${isActive}"> 1.47 - <!-- VERSIONS --> 1.48 - <c:set var="componentNode" value="${not empty viewmodel.componentFilter ? viewmodel.componentFilter.node : 'all-components'}"/> 1.49 - <div class="menuEntry level-1" <c:if test="${viewmodel.selectedPage eq ProjectView.SELECTED_PAGE_VERSIONS}">data-active</c:if> > 1.50 - <a href="projects/${projectInfo.project.node}/versions/"> 1.51 - <fmt:message key="navmenu.versions"/> 1.52 - </a> 1.53 - </div> 1.54 - <div class="menuEntry level-2" <c:if test="${viewmodel.versionFilter eq ProjectView.ALL_VERSIONS}">data-active</c:if>> 1.55 - <div class="navmenu-icon" style="background: black"></div> 1.56 - <a href="projects/${projectInfo.project.node}/${componentNode}/all-versions/issues/"> 1.57 - <fmt:message key="navmenu.all" /> 1.58 - </a> 1.59 - </div> 1.60 - <div class="menuEntry level-2" <c:if test="${viewmodel.versionFilter eq ProjectView.NO_VERSION}">data-active</c:if>> 1.61 - <div class="navmenu-icon" style="background: black"></div> 1.62 - <a href="projects/${projectInfo.project.node}/${componentNode}/no-version/issues/"> 1.63 - <fmt:message key="navmenu.unassigned" /> 1.64 - </a> 1.65 - </div> 1.66 - <c:forEach var="version" items="${viewmodel.projectInfo.versions}"> 1.67 - <c:set var="isVersionActive" value="${viewmodel.versionFilter eq version}" /> 1.68 - <c:if test="${version.status ne VersionStatus.Deprecated or isVersionActive}"> 1.69 - <div class="menuEntry level-2" <c:if test="${isVersionActive}">data-active</c:if> 1.70 - title="<fmt:message key="version.status.${version.status}" />"> 1.71 - <div class="navmenu-icon version-${version.status}"></div> 1.72 - <a href="projects/${projectInfo.project.node}/${componentNode}/${version.node}/issues/"> 1.73 - <c:out value="${version.name}"/> 1.74 - </a> 1.75 - </div> 1.76 - </c:if> 1.77 - </c:forEach> 1.78 - <!-- COMPONENTS --> 1.79 - <c:set var="versionNode" value="${not empty viewmodel.versionFilter ? viewmodel.versionFilter.node : 'all-versions'}"/> 1.80 - <div class="menuEntry level-1" <c:if test="${viewmodel.selectedPage eq ProjectView.SELECTED_PAGE_COMPONENTS}">data-active</c:if>> 1.81 - <a href="projects/${projectInfo.project.node}/components/"> 1.82 - <fmt:message key="navmenu.components"/> 1.83 - </a> 1.84 - </div> 1.85 - <div class="menuEntry level-2" <c:if test="${viewmodel.componentFilter eq ProjectView.ALL_COMPONENTS}">data-active</c:if>> 1.86 - <div class="navmenu-icon" style="background: black"></div> 1.87 - <a href="projects/${projectInfo.project.node}/all-components/${versionNode}/issues/"> 1.88 - <fmt:message key="navmenu.all" /> 1.89 - </a> 1.90 - </div> 1.91 - <div class="menuEntry level-2" <c:if test="${viewmodel.componentFilter eq ProjectView.NO_COMPONENT}">data-active</c:if>> 1.92 - <div class="navmenu-icon" style="background: black"></div> 1.93 - <a href="projects/${projectInfo.project.node}/no-component/${versionNode}/issues/"> 1.94 - <fmt:message key="navmenu.unassigned" /> 1.95 - </a> 1.96 - </div> 1.97 - <c:forEach var="component" items="${viewmodel.projectInfo.components}"> 1.98 - <c:set var="isComponentActive" value="${viewmodel.componentFilter eq component}" /> 1.99 - <div class="menuEntry level-2" <c:if test="${isComponentActive}">data-active</c:if> > 1.100 - <div class="navmenu-icon" style="background-color: ${component.color}"></div> 1.101 - <a href="projects/${projectInfo.project.node}/${component.node}/${versionNode}/issues/"> 1.102 - <c:out value="${component.name}"/> 1.103 - </a> 1.104 - </div> 1.105 - </c:forEach> 1.106 - </c:if> 1.107 -</c:forEach>