1 16 package org.jmanage.webui.actions.config; 17 18 import org.jmanage.webui.actions.BaseAction; 19 import org.jmanage.webui.util.WebContext; 20 import org.jmanage.webui.util.Forwards; 21 import org.jmanage.webui.forms.ConfigureForm; 22 import org.jmanage.core.util.JManageProperties; 23 import org.jmanage.core.services.AccessController; 24 import org.apache.struts.action.ActionForward; 25 import org.apache.struts.action.ActionMapping; 26 import org.apache.struts.action.ActionForm; 27 28 import javax.servlet.http.HttpServletRequest ; 29 import javax.servlet.http.HttpServletResponse ; 30 import java.util.Properties ; 31 import java.io.OutputStream ; 32 import java.io.FileOutputStream ; 33 import java.io.FileNotFoundException ; 34 35 40 public class ConfigureAction extends BaseAction { 41 42 public ActionForward execute (WebContext context, 43 ActionMapping mapping, 44 ActionForm actionForm, 45 HttpServletRequest request, 46 HttpServletResponse response) 47 throws Exception { 48 AccessController.checkAccess(context.getServiceContext(), 49 ACL_EDIT_JMANAGE_CONFIG); 50 JManageProperties jmanageProperties = JManageProperties.getInstance(); 51 ConfigureForm configureForm = (ConfigureForm)actionForm; 52 jmanageProperties.storeMaxLoginAttempts(configureForm.getMaxLoginAttempts()); 53 return mapping.findForward(Forwards.SUCCESS); 54 } 55 } 56 | Popular Tags |