拦截器手动添加spring注入方法 :
ActionContext actionContext = invocation.getInvocationContext();
ServletContext context = (ServletContext) actionContext.get(StrutsStatics.SERVLET_CONTEXT);
ApplicationContext ctx = WebApplicationContextUtils.getWebApplicationContext(context);
PopedomDao popedomDao =(PopedomDao)ctx.getBean("PopedomDao");
ServletContext context = (ServletContext) actionContext.get(StrutsStatics.SERVLET_CONTEXT);
ApplicationContext ctx = WebApplicationContextUtils.getWebApplicationContext(context);
PopedomDao popedomDao =(PopedomDao)ctx.getBean("PopedomDao");
转载于:https://blog.51cto.com/dingjibin/1142522