comparison gnv/src/main/webapp/WEB-INF/jsp/index.jsp @ 991:33198e55371c

Improved session handling in the gui. If a session has timed out, the user gets to the start point - the fis selection. gnv/trunk@1192 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 10 Jun 2010 15:13:08 +0000
parents cfea6dacd52a
children 9b126bceb0b2
comparison
equal deleted inserted replaced
990:56b22bc68dfa 991:33198e55371c
30 } 30 }
31 31
32 Object exceptionMessage = request.getAttribute(CommunicationKeys.REQUEST_EXCEPTION_MESSAGE_ID); 32 Object exceptionMessage = request.getAttribute(CommunicationKeys.REQUEST_EXCEPTION_MESSAGE_ID);
33 exceptionMessage = (exceptionMessage != null ? exceptionMessage.toString().replaceAll(" ", ".").replaceAll(":",".").toLowerCase() : null); 33 exceptionMessage = (exceptionMessage != null ? exceptionMessage.toString().replaceAll(" ", ".").replaceAll(":",".").toLowerCase() : null);
34 exceptionMessage = (exceptionMessage != null && exceptionMessage.toString().endsWith(".") ? exceptionMessage.toString().substring(0,exceptionMessage.toString().length()-1) : exceptionMessage); 34 exceptionMessage = (exceptionMessage != null && exceptionMessage.toString().endsWith(".") ? exceptionMessage.toString().substring(0,exceptionMessage.toString().length()-1) : exceptionMessage);
35
36 Object sessionException = request.getAttribute(CommunicationKeys.REQUEST_EXCEPTION_SESSION_ID);
37 sessionException = (sessionException != null ? sessionException.toString().replaceAll(" ", ".").replaceAll(":",".").toLowerCase() : null);
38 sessionException = (sessionException != null && sessionException.toString().endsWith(".") ? sessionException.toString().substring(0,sessionException.toString().length()-1) : sessionException);
35 39
36 boolean showmapviewercallBody = request.getAttribute("MAPVIEWERCALL") != null; 40 boolean showmapviewercallBody = request.getAttribute("MAPVIEWERCALL") != null;
37 41
38 String exceptionProject = (String) request.getAttribute(CommunicationKeys.REQUEST_EXCEPTION_PROJECT); 42 String exceptionProject = (String) request.getAttribute(CommunicationKeys.REQUEST_EXCEPTION_PROJECT);
39 exceptionProject = exceptionProject != null ? exceptionProject.toLowerCase() : null; 43 exceptionProject = exceptionProject != null ? exceptionProject.toLowerCase() : null;
137 <bean:message key="application.reload"/> 141 <bean:message key="application.reload"/>
138 </a> 142 </a>
139 </p> 143 </p>
140 </div> 144 </div>
141 <%}%> 145 <%}%>
146 <%if (sessionException != null){ %>
147 <div class="errormsg" id="load_error">
148 <bean-el:message key="<%=sessionException.toString()%>"/>
149 </div>
150 <%}%>
142 <%if (chart != null) {%> 151 <%if (chart != null) {%>
143 <%-- render chart options if existing for this state --%> 152 <%-- render chart options if existing for this state --%>
144 <jsp:include page="includes/display_diagramm_inc.jsp"></jsp:include> 153 <jsp:include page="includes/display_diagramm_inc.jsp"></jsp:include>
145 <%}%> 154 <%}%>
146 155

http://dive4elements.wald.intevation.org