1、
tEdasArchiveLogService = (TEdasArchiveLogService) SpringContextHolder.getBean("TEdasArchiveLogService");
2、
ServletContext sc = request.getSession().getServletContext();
//获取spring容器
ApplicationContext app=WebApplicationContextUtils.getRequiredWebApplicationContext(sc);
TEdasFilesService tEdasFilesService=app.getBean(TEdasFilesService.class);