Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class ScheduleLoadController{
- // @RequestMapping(value="/ScheduleLoad", method = RequestMethod.GET)
- // public ModelAndView ScheduleLoad() {
- // return new ModelAndView("ScheduleLoad","command", new ScheduleLoad());
- // }
- //
- public ModelAndView onSubmit(HttpServletRequest request, HttpServletResponse response, Object command, BindException errors)
- throws Exception {
- String aMessage = "ScheduleLoad Test";
- ApplicationContext context = new ClassPathXmlApplicationContext("spring-config.xml");
- ScheduleLoad scheduleLoadData = (ScheduleLoad)command;
- ScheduleLoadJDBCTemplate ScheduleLoadJDBCTemplate = (ScheduleLoadJDBCTemplate)context.getBean("ScheduleLoadJDBCTemplate");
- System.out.println("------Records Creation--------" );
- ScheduleLoadJDBCTemplate.create("2011");
- return new ModelAndView("confirmLoadTest","scheduleLoadData",scheduleLoadData);
- }
- // @Override
- // public ModelAndView handleRequest(HttpServletRequest arg0,
- // HttpServletResponse arg1) throws Exception {
- //
- //
- // String aMessage = "ScheduleLoad Test";
- //
- // ApplicationContext context = new ClassPathXmlApplicationContext("spring-config.xml");
- //
- // ScheduleLoadJDBCTemplate ScheduleLoadJDBCTemplate = (ScheduleLoadJDBCTemplate)context.getBean("ScheduleLoadJDBCTemplate");
- //
- // System.out.println("------Records Creation--------" );
- // ScheduleLoadJDBCTemplate.create("2011");
- //
- // ModelAndView modelAndView = new ModelAndView("scheduleLoad");
- // modelAndView.addObject("message", aMessage);
- // return modelAndView;
- // }
- }
Advertisement
Add Comment
Please, Sign In to add comment