| 24 OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
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. |
25 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 26 --%> |
26 --%> |
| 27 <%@page contentType="text/html" pageEncoding="UTF-8" trimDirectiveWhitespaces="true" %> |
27 <%@page contentType="text/html" pageEncoding="UTF-8" trimDirectiveWhitespaces="true" %> |
| 28 <%@page import="de.uapcore.lightpit.Constants" %> |
28 <%@page import="de.uapcore.lightpit.Constants" %> |
| |
29 <%@page import="de.uapcore.lightpit.modules.ProjectsModule" %> |
| 29 <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> |
30 <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> |
| 30 <%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> |
31 <%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> |
| 31 <%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> |
32 <%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> |
| 32 |
33 |
| 33 <%-- Make the base href easily available at request scope --%> |
34 <%-- Make the base href easily available at request scope --%> |
| 36 <%-- Define an alias for the request path --%> |
37 <%-- Define an alias for the request path --%> |
| 37 <c:set scope="page" var="requestPath" value="${requestScope[Constants.REQ_ATTR_PATH]}"/> |
38 <c:set scope="page" var="requestPath" value="${requestScope[Constants.REQ_ATTR_PATH]}"/> |
| 38 |
39 |
| 39 <%-- Define an alias for the main menu --%> |
40 <%-- Define an alias for the main menu --%> |
| 40 <c:set scope="page" var="mainMenu" value="${requestScope[Constants.REQ_ATTR_MENU]}"/> |
41 <c:set scope="page" var="mainMenu" value="${requestScope[Constants.REQ_ATTR_MENU]}"/> |
| 41 |
|
| 42 <%-- Define an alias for the sub menu --%> |
|
| 43 <c:set scope="page" var="subMenu" value="${requestScope[Constants.REQ_ATTR_SUB_MENU]}"/> |
|
| 44 |
42 |
| 45 <%-- Define an alias for the fragment name --%> |
43 <%-- Define an alias for the fragment name --%> |
| 46 <c:set scope="page" var="fragment" value="${requestScope[Constants.REQ_ATTR_FRAGMENT]}"/> |
44 <c:set scope="page" var="fragment" value="${requestScope[Constants.REQ_ATTR_FRAGMENT]}"/> |
| 47 |
45 |
| 48 <%-- Define an alias for the optional redirect location --%> |
46 <%-- Define an alias for the optional redirect location --%> |
| 56 |
54 |
| 57 <%-- Apply the session locale (should always be present, but check nevertheless) --%> |
55 <%-- Apply the session locale (should always be present, but check nevertheless) --%> |
| 58 <c:if test="${not empty sessionScope[Constants.SESSION_ATTR_LANGUAGE]}"> |
56 <c:if test="${not empty sessionScope[Constants.SESSION_ATTR_LANGUAGE]}"> |
| 59 <fmt:setLocale scope="request" value="${sessionScope[Constants.SESSION_ATTR_LANGUAGE]}"/> |
57 <fmt:setLocale scope="request" value="${sessionScope[Constants.SESSION_ATTR_LANGUAGE]}"/> |
| 60 </c:if> |
58 </c:if> |
| |
59 |
| |
60 <%-- Selected project, if any --%> |
| |
61 <c:set scope="page" var="selectedProject" value="${sessionScope[ProjectsModule.SESSION_ATTR_SELECTED_PROJECT]}"/> |
| 61 |
62 |
| 62 <!DOCTYPE html> |
63 <!DOCTYPE html> |
| 63 <html> |
64 <html> |
| 64 <head> |
65 <head> |
| 65 <base href="${baseHref}"> |
66 <base href="${baseHref}"> |
| 78 </c:if> |
79 </c:if> |
| 79 </head> |
80 </head> |
| 80 <body> |
81 <body> |
| 81 <div id="mainMenu"> |
82 <div id="mainMenu"> |
| 82 <c:forEach var="menu" items="${mainMenu}"> |
83 <c:forEach var="menu" items="${mainMenu}"> |
| 83 <%@ include file="../jspf/menu-entry.jspf" %> |
84 <div class="menuEntry" |
| |
85 <c:set var="menuPath" value="/${menu.pathName}"/> |
| |
86 <c:if test="${fn:startsWith(requestPath, menuPath)}"> |
| |
87 data-active |
| |
88 </c:if> |
| |
89 > |
| |
90 <a href="${menu.pathName}"> |
| |
91 <fmt:bundle basename="${menu.resourceKey.bundle}"> |
| |
92 <fmt:message key="${menu.resourceKey.key}"/> |
| |
93 </fmt:bundle> |
| |
94 </a> |
| |
95 </div> |
| 84 </c:forEach> |
96 </c:forEach> |
| 85 </div> |
97 </div> |
| 86 <c:if test="${not empty subMenu}"> |
98 <div id="breadcrumbs"> |
| 87 <div id="subMenu"> |
99 <%-- TODO: find a strategy to define the breadcrumbs --%> |
| 88 <c:forEach var="menu" items="${subMenu}"> |
100 </div> |
| 89 <%@ include file="../jspf/menu-entry.jspf" %> |
|
| 90 </c:forEach> |
|
| 91 </div> |
|
| 92 </c:if> |
|
| 93 <div id="content-area"> |
101 <div id="content-area"> |
| 94 <c:if test="${not empty fragment}"> |
102 <c:if test="${not empty fragment}"> |
| 95 <fmt:setBundle scope="request" basename="${moduleInfo.bundleBaseName}"/> |
103 <fmt:setBundle scope="request" basename="${moduleInfo.bundleBaseName}"/> |
| 96 <fmt:setBundle scope="request" var="lightpit_bundle" basename="localization.lightpit"/> |
104 <fmt:setBundle scope="request" var="lightpit_bundle" basename="localization.lightpit"/> |
| 97 <c:import url="${fragment}" /> |
105 <c:import url="${fragment}" /> |