1 2 package org.roller.presentation.weblog.actions; 3 4 import org.apache.struts.action.ActionForm; 5 import org.apache.struts.action.ActionForward; 6 import org.apache.struts.action.ActionMapping; 7 import org.apache.struts.actions.DispatchAction; 8 9 import java.io.IOException ; 10 11 import javax.servlet.ServletException ; 12 import javax.servlet.http.HttpServletRequest ; 13 import javax.servlet.http.HttpServletResponse ; 14 15 import org.roller.RollerException; 16 import org.roller.model.WeblogManager; 17 import org.roller.presentation.RollerRequest; 18 import org.roller.presentation.weblog.formbeans.WeblogQueryForm; 19 20 21 30 public final class WeblogQueryAction extends DispatchAction 31 { 32 38 public ActionForward query( 39 ActionMapping mapping, 40 ActionForm actionForm, 41 HttpServletRequest request, 42 HttpServletResponse response) 43 throws IOException , ServletException , RollerException 44 { 45 WeblogQueryForm form = (WeblogQueryForm)actionForm; 46 RollerRequest rreq = RollerRequest.getRollerRequest(request); 47 WeblogManager wmgr = rreq.getRoller().getWeblogManager(); 48 49 request.setAttribute("model", new WeblogQueryPageModel( 50 request, 51 response, 52 mapping, 53 rreq.getWebsite(), 54 form.getCategoryId(), 55 form.getStartDateString(), 56 form.getEndDateString(), 57 form.getStatus(), 58 form.getMaxEntries())); 59 60 return mapping.findForward("weblogQuery.page"); 61 } 62 } 63 | Popular Tags |