src/main/webapp/WEB-INF/jsp/project-details.jsp

Wed, 06 Jan 2021 16:20:32 +0100

author
Mike Becker <universe@uap-core.de>
date
Wed, 06 Jan 2021 16:20:32 +0100
changeset 181
502a10e24b85
parent 180
009700915269
child 184
e8eecee6aadf
permissions
-rw-r--r--

renames several resource keys

     1 <%--
     2 DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
     4 Copyright 2021 Mike Becker. All rights reserved.
     6 Redistribution and use in source and binary forms, with or without
     7 modification, are permitted provided that the following conditions are met:
     9 1. Redistributions of source code must retain the above copyright
    10 notice, this list of conditions and the following disclaimer.
    12 2. Redistributions in binary form must reproduce the above copyright
    13 notice, this list of conditions and the following disclaimer in the
    14 documentation and/or other materials provided with the distribution.
    16 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
    17 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
    18 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
    19 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
    20 FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
    21 DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
    22 SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
    23 CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
    24 OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
    25 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    26 --%>
    27 <%@page pageEncoding="UTF-8" import="de.uapcore.lightpit.viewmodel.ProjectView" %>
    28 <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    29 <%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
    30 <%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
    32 <jsp:useBean id="viewmodel" type="de.uapcore.lightpit.viewmodel.ProjectDetailsView" scope="request" />
    34 <c:set var="project" scope="page" value="${viewmodel.projectInfo.project}"/>
    35 <c:set var="component" scope="page" value="${viewmodel.componentFilter}"/>
    36 <%@include file="../jspf/project-header.jspf"%>
    38 <div id="tool-area">
    39     <c:remove var="createIssueParams"/>
    40     <c:if test="${viewmodel.versionFilter.id gt 0}">
    41         <c:set var="createIssueParams">&vid=${viewmodel.versionFilter.id}</c:set>
    42     </c:if>
    43     <c:if test="${viewmodel.componentFilter.id gt 0}">
    44         <c:set var="createIssueParams">${createIssueParams}&cid=${viewmodel.componentFilter.id}</c:set>
    45     </c:if>
    46     <c:if test="${not empty createIssueParams}">
    47         <c:set var="createIssueParams">?${fn:substringAfter(createIssueParams, "&")}</c:set>
    48     </c:if>
    49     <a href="./projects/${project.node}/create-issue${createIssueParams}" class="button"><fmt:message key="button.issue.create"/></a>
    50     <c:if test="${viewmodel.versionFilter.id gt 0}">
    51         <a href="./projects/${project.node}/versions/${viewmodel.versionFilter.node}/edit" class="button"><fmt:message key="button.version.edit"/></a>
    52     </c:if>
    53     <a href="./projects/${project.node}/create-version" class="button"><fmt:message key="button.version.create"/></a>
    54     <c:if test="${viewmodel.componentFilter.id gt 0}">
    55         <a href="./projects/${project.node}/components/${viewmodel.componentFilter.node}/edit" class="button"><fmt:message key="button.component.edit"/></a>
    56     </c:if>
    57     <a href="./projects/${project.node}/create-component" class="button"><fmt:message key="button.component.create"/></a>
    58 </div>
    60 <h2><fmt:message key="progress" /></h2>
    62 <c:set var="summary" value="${viewmodel.projectInfo.issueSummary}" />
    63 <%@include file="../jspf/issue-summary.jspf"%>
    65 <c:choose>
    66     <c:when test="${viewmodel.versionFilter eq ProjectView.NO_VERSION or viewmodel.versionFilter eq ProjectView.ALL_VERSIONS}">
    67         <h2>
    68             <c:if test="${viewmodel.versionFilter eq ProjectView.NO_VERSION}">
    69                 <fmt:message key="issue.without-version" />
    70             </c:if>
    71             <c:if test="${viewmodel.versionFilter ne ProjectView.NO_VERSION}">
    72                 <fmt:message key="issues" />
    73             </c:if>
    74         </h2>
    75         <c:set var="summary" value="${viewmodel.projectDetails.issueSummary}"/>
    76         <c:set var="issues" value="${viewmodel.projectDetails.issues}"/>
    77         <%@include file="../jspf/issue-summary.jspf"%>
    78         <c:if test="${not empty issues}">
    79             <%@include file="../jspf/issue-list.jspf"%>
    80         </c:if>
    81     </c:when>
    82     <c:otherwise>
    83         <c:set var="versionInfo" value="${viewmodel.projectDetails.versionInfo}"/>
    84         <h2>
    85             <fmt:message key="version" /> <c:out value="${versionInfo.version.name}" /> - <fmt:message key="version.status.${versionInfo.version.status}"/>
    86         </h2>
    88         <h3><fmt:message key="issues.resolved"/> </h3>
    89         <c:set var="summary" value="${versionInfo.resolvedTotal}"/>
    90         <%@include file="../jspf/issue-summary.jspf"%>
    91         <c:set var="issues" value="${versionInfo.resolved}"/>
    92         <c:if test="${not empty issues}">
    93             <%@include file="../jspf/issue-list.jspf"%>
    94         </c:if>
    96         <c:set var="issues" value="${versionInfo.reported}"/>
    97         <c:if test="${not empty issues}">
    98             <h3><fmt:message key="issues.reported"/> </h3>
    99             <c:set var="summary" value="${versionInfo.reportedTotal}"/>
   100             <%@include file="../jspf/issue-summary.jspf"%>
   101             <%@include file="../jspf/issue-list.jspf"%>
   102         </c:if>
   103     </c:otherwise>
   104 </c:choose>

mercurial