@Override public void proccess(HttpServletRequest request, HttpServletResponse response) { List<String> ls = new ArrayList<String>(); for (int i = 0; i < Integer.parseInt(request.getParameter("tags_num")); i++) { ls.add(request.getParameter("guide_tag" + String.valueOf(i))); } List<GuideBean> lgb = DAOFactory.getMySQLDAOFactory().getGuideDAO().search(ls); request.setAttribute("data", lgb); this.dispatch(request, response); }
@Override public void proccess(HttpServletRequest request, HttpServletResponse response) { CommentsTO commentsTO = new CommentsTO( request.getParameter("comment"), (String) request.getSession().getAttribute("user_email"), Integer.parseInt(request.getParameter("id"))); boolean flag = DAOFactory.getMySQLDAOFactory().getCommentsDAO().comment(commentsTO); if (flag) { request.setAttribute("data", "true"); } else { request.setAttribute("data", "false"); } dispatch(request, response); }