1.
1 27 8 11 HotelMaster 12 1314 17 18 19 21 22webAppRootKey 15hotelmaster.root 1623 31 32 33contextConfigLocation 2425 /WEB-INF/hotel-security.xml, 26 /WEB-INF/hotel-hibernate.xml, 27 /WEB-INF/hotel-servlet.xml, 28 /WEB-INF/hotel-services.xml 29 3034 37 38log4jConfigLocation 35/WEB-INF/classes/log4j.properties 3639 42 43 44log4jRefreshInterval 4060000 4145 48 49acegiAjaxFilter 46com.hotelmaster.home.web.filter.AcegiAjaxFilter 4750 53 54logoutAjaxFilter 51com.hotelmaster.home.web.filter.LogoutAjaxFilter 5255 62 63acegiFilterChain 56org.acegisecurity.util.FilterToBeanProxy 5758 61targetClass 59org.acegisecurity.util.FilterChainProxy 6064 67 68acegiAjaxFilter 65/j_acegi_security_check 6669 72 73 74logoutAjaxFilter 70/userLogout.htm 7175 78 79acegiFilterChain 76/j_acegi_security_check 7780 84 85acegiFilterChain 81*.htm 82REQUEST 8386 90 91 92acegiFilterChain 87*.jsp 88REQUEST 8993 97 9894 org.springframework.web.util.Log4jConfigListener 95 9699 101 102 103org.springframework.web.context.ContextLoaderListener 100104 112 113dwr-invoker 105DWR Servlet 106org.directwebremoting.servlet.DwrServlet 107108 111debug 109true 110114 117 118 119 120 121dwr-invoker 115/dwr/* 116122 132 133dispatcherServlet 123124 org.springframework.web.servlet.DispatcherServlet125 126127 130contextConfigLocation 128/WEB-INF/hotel-servlet.xml 1290 131134 137 138dispatcherServlet 135*.htm 136139 141 142120 140143 145/WEB-INF/pages/index.jsp 144
2.
1 26 7 8 12 13 29 30 3114 15 2816 27userLoginController 17homeController 18frontdeskController 19checkinController 20guestInforController 21reservController 22guestHistoryController 23checkoutController 24basicSettingController 25businessCalculationController 2633 35 3634 37 40 4138 39 42 45 4643 44 47 48 49 5051 5552 53 5456 60 6157 58 5962 69 7063 64 6566 67 6871 78 7972 73 7475 76 7780 87 8881 82 8384 85 8689 96 9790 91 9293 94 9598 108 10999 100 101102 103 104105 106 107110 117 118111 112 113114 115 116119 126 127120 121 122123 124 125128 135129 130 131132 133 134
3.
1 package com.hotelmaster.home.web.login; 2 import javax.servlet.http.HttpServletRequest; 3 import javax.servlet.http.HttpServletResponse; 4 5 import org.apache.log4j.Logger; 6 import org.springframework.web.servlet.ModelAndView; 7 import org.springframework.web.servlet.mvc.multiaction.MultiActionController; 8 9 10 /**11 * Class description goes here.12 * 13 * @author FoGhost14 * @Date Mar 21, 200815 */16 public class UserLoginController extends MultiActionController{17 /** Logger for this class and subclasses */18 protected final Logger logger = Logger.getLogger(UserLoginController.class);19 20 public ModelAndView init (HttpServletRequest request,HttpServletResponse response) throws Exception{21 return new ModelAndView("userLogin");22 //return null;23 }24 25 public ModelAndView userLogin(HttpServletRequest request,HttpServletResponse response)throws Exception{26 String userID=(String) request.getParameter("userID").trim();27 String userPass=(String) request.getParameter("userPass").trim();28 if(userID.equals("admin")&& userPass.equals("admin") ){29 //return new ModelAndView("login");30 request.getSession().setAttribute("user", "admin");31 response.getWriter().write("{success: true}");32 return null;33 }else{34 35 response.setContentType("text/json; charset=utf-8");36 response.getWriter().write("{success: false,errors:{ reason: '用户名密码错误' }}");37 return null;38 }39 }40 }