18 package org.turro.elephant;
20 import java.io.IOException;
21 import java.util.logging.Level;
22 import java.util.logging.Logger;
23 import javax.servlet.http.HttpServletRequest;
24 import javax.servlet.http.HttpSession;
25 import org.turro.action.IAgreements;
26 import org.turro.action.Interceptors;
27 import org.turro.auth.Authentication;
28 import org.turro.elephant.context.Application;
29 import org.turro.elephant.context.ElephantContext;
30 import org.turro.i18n.I_;
31 import org.turro.zul.frame.Framework;
32 import org.zkoss.web.fn.ServletFns;
33 import org.zkoss.zk.ui.Executions;
34 import org.zkoss.zk.ui.GenericRichlet;
35 import org.zkoss.zk.ui.Page;
36 import org.zkoss.zk.ui.ext.AfterCompose;
51 Executions.sendRedirect(
"/user?redir=/app/frame");
57 if(frame instanceof AfterCompose) {
65 Executions.sendRedirect(
"/user");
68 }
catch (IOException ex) {
73 public static void setLocale(HttpServletRequest request) {
74 if(request ==
null && org.zkoss.web.fn.ServletFns.getCurrentContext() !=
null) {
75 request = (HttpServletRequest) ServletFns.getCurrentRequest();
78 HttpSession session = request.getSession(
false);
81 session.setAttribute(
"i_",
I_.
api());
82 session.setAttribute(
"i",
I_.
map());
86 request.setAttribute(
"i_",
I_.
api());
87 request.setAttribute(
"i",
I_.
map());
static boolean executeApp(Application application, Map< String, String[]> parameterMap)
static boolean isWebapp()
static void setLocale(HttpServletRequest request)
abstract HttpServletResponse getHttpServletResponse()
HttpSession getHttpSession(boolean create)
static Application getApplication()
abstract HttpServletRequest getHttpServletRequest()
static String logMsg(String msg)
static I18nByKey byKeyMap()
static I18nApiWrapper api()
static I18nMapWrapper map()
static I18nCompatibilityMap compatibilityMap()
void addContent(String label, String src)
PortalWindows getPortalWindows()
static boolean checkAgreements(HttpServletRequest request, HttpServletResponse response)