Package net.sf.pmr.struts.administration.core.form

Examples of net.sf.pmr.struts.administration.core.form.UserForm


        if (StringUtils.isNotEmpty( (String) request.getParameter("persistanceId"))) {

            User user = userService.findByPersistanceId(Integer.parseInt(request.getParameter("persistanceId").toString()));
           
            // Populate the form
            UserForm userForm = (UserForm) form;
           
            userForm.setFirstName(user.getFirstName());
            userForm.setPersistanceId(user.getPersistanceId());
            userForm.setLastName(user.getLastName());
            userForm.setLogin(user.getLogin());
            userForm.setEmail(user.getEmail());
            userForm.setPassword(user.getPassword());
            userForm.setPersistanceVersion(user.getPersistanceVersion());
           
        // populate the summary
            request.setAttribute("numberOfProject", user.getProjects().size());
            request.setAttribute("persistanceId", user.getPersistanceId());
View Full Code Here


      throws Exception {
     
    // get the user service
    UserService userService = CoreObjectFactory.getUserService();
    // get the form
    UserForm userForm = (UserForm) form;
   
    // TODO faire une seul m�thode userService.save
   
    // save the user
    Errors errors = null;
      errors = userService.addOrUpdate(userForm.getPersistanceId(), userForm.getFirstName(), userForm.getLastName(), userForm.getLogin(), userForm.getPassword(), userForm.getEmail(), userForm.getPersistanceVersion());       
   
    // Convert into struts action errors
    ActionMessages actionMessages = new ActionMessages();
   
    if (errors.hasErrors()) {
View Full Code Here

TOP

Related Classes of net.sf.pmr.struts.administration.core.form.UserForm

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.