# HG changeset patch # User Mike Becker # Date 1589388328 -7200 # Node ID 9abf0bf44c7b92a017bd662f7c63c6b2393d230f # Parent f962ff9dd44e6b6618e24442821c8a82fa5ee0f8 renames some crappy constants diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/AbstractLightPITServlet.java --- a/src/main/java/de/uapcore/lightpit/AbstractLightPITServlet.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/AbstractLightPITServlet.java Wed May 13 18:45:28 2020 +0200 @@ -53,7 +53,7 @@ private static final Logger LOG = LoggerFactory.getLogger(AbstractLightPITServlet.class); - private static final String HTML_FULL_DISPATCHER = Functions.jspPath("html_full"); + private static final String SITE_JSP = Functions.jspPath("site"); /** * The EL proxy is necessary, because the EL resolver cannot handle annotation properties. @@ -234,7 +234,7 @@ throws IOException, ServletException { req.setAttribute(Constants.REQ_ATTR_MENU, getModuleManager().getMainMenu()); - req.getRequestDispatcher(HTML_FULL_DISPATCHER).forward(req, resp); + req.getRequestDispatcher(SITE_JSP).forward(req, resp); } private Optional findMapping(HttpMethod method, HttpServletRequest req) { @@ -248,7 +248,7 @@ switch (type) { case NONE: return; - case HTML_FULL: + case HTML: forwardToFullView(req, resp); return; // TODO: implement remaining response types diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/ResponseType.java --- a/src/main/java/de/uapcore/lightpit/ResponseType.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/ResponseType.java Wed May 13 18:45:28 2020 +0200 @@ -33,7 +33,7 @@ /** * Renders a full HTML view including the header. */ - HTML_FULL, + HTML, /** * Renders a HTML fragment only. * May be used for AJAX responses. diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/modules/ErrorModule.java --- a/src/main/java/de/uapcore/lightpit/modules/ErrorModule.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/modules/ErrorModule.java Wed May 13 18:45:28 2020 +0200 @@ -56,7 +56,7 @@ setStylesheet(req, "error"); setDynamicFragment(req, "error"); - return ResponseType.HTML_FULL; + return ResponseType.HTML; } @RequestMapping(requestPath = "404", method = HttpMethod.GET) diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/modules/HomeModule.java --- a/src/main/java/de/uapcore/lightpit/modules/HomeModule.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/modules/HomeModule.java Wed May 13 18:45:28 2020 +0200 @@ -49,6 +49,6 @@ @RequestMapping(method = HttpMethod.GET) public ResponseType handle() { - return ResponseType.HTML_FULL; + return ResponseType.HTML; } } diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/modules/LanguageModule.java --- a/src/main/java/de/uapcore/lightpit/modules/LanguageModule.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/modules/LanguageModule.java Wed May 13 18:45:28 2020 +0200 @@ -92,7 +92,7 @@ setStylesheet(req, "language"); setDynamicFragment(req, "language"); - return ResponseType.HTML_FULL; + return ResponseType.HTML; } @RequestMapping(method = HttpMethod.POST) diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/modules/ProjectsModule.java --- a/src/main/java/de/uapcore/lightpit/modules/ProjectsModule.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/modules/ProjectsModule.java Wed May 13 18:45:28 2020 +0200 @@ -49,6 +49,6 @@ @RequestMapping(method = HttpMethod.GET) public ResponseType handle(HttpServletRequest req, DataAccessObjects dao) { - return ResponseType.HTML_FULL; + return ResponseType.HTML; } } diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/java/de/uapcore/lightpit/modules/VersionsModule.java --- a/src/main/java/de/uapcore/lightpit/modules/VersionsModule.java Wed May 13 18:40:52 2020 +0200 +++ b/src/main/java/de/uapcore/lightpit/modules/VersionsModule.java Wed May 13 18:45:28 2020 +0200 @@ -48,6 +48,6 @@ @RequestMapping(method = HttpMethod.GET) public ResponseType handle(HttpServletRequest req, DataAccessObjects dao) { - return ResponseType.HTML_FULL; + return ResponseType.HTML; } } diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/webapp/WEB-INF/jsp/html_full.jsp --- a/src/main/webapp/WEB-INF/jsp/html_full.jsp Wed May 13 18:40:52 2020 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,91 +0,0 @@ -<%-- -DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. - -Copyright 2018 Mike Becker. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - -1. Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - -2. Redistributions in binary form must reproduce the above copyright -notice, this list of conditions and the following disclaimer in the -documentation and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ---%> -<%@page contentType="text/html" pageEncoding="UTF-8" trimDirectiveWhitespaces="true" %> -<%@page import="de.uapcore.lightpit.Constants" %> -<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> -<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> -<%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> - -<%-- Define an alias for the main menu --%> - - -<%-- Define an alias for the fragment name --%> - - -<%-- Define an alias for the additional stylesheet --%> - - -<%-- Define an alias for the module info --%> - - -<%-- Apply the session locale (should always be present, but check nevertheless) --%> - - - - - - - - - LightPIT - - <fmt:bundle basename="${moduleInfo.bundleBaseName}"> - <fmt:message key="${moduleInfo.titleKey}" /> - </fmt:bundle> - - - - - - - - - - -
- - - - -
- - diff -r f962ff9dd44e -r 9abf0bf44c7b src/main/webapp/WEB-INF/jsp/site.jsp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/main/webapp/WEB-INF/jsp/site.jsp Wed May 13 18:45:28 2020 +0200 @@ -0,0 +1,91 @@ +<%-- +DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. + +Copyright 2018 Mike Becker. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright +notice, this list of conditions and the following disclaimer in the +documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +--%> +<%@page contentType="text/html" pageEncoding="UTF-8" trimDirectiveWhitespaces="true" %> +<%@page import="de.uapcore.lightpit.Constants" %> +<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> +<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> +<%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> + +<%-- Define an alias for the main menu --%> + + +<%-- Define an alias for the fragment name --%> + + +<%-- Define an alias for the additional stylesheet --%> + + +<%-- Define an alias for the module info --%> + + +<%-- Apply the session locale (should always be present, but check nevertheless) --%> + + + + + + + + + LightPIT - + <fmt:bundle basename="${moduleInfo.bundleBaseName}"> + <fmt:message key="${moduleInfo.titleKey}" /> + </fmt:bundle> + + + + + + + + + + +
+ + + + +
+ +