Package models

Examples of models.UserProfile


      NamespaceManager.set(old);
    }
  }
 
  private void addProfileToUser(String username, ProfileType profile) {
    UserProfile user_profile = new UserProfile(User.findByUsername(username),
        Profile.findByType(profile));
    user_profile.insert();
  }
View Full Code Here


    validation.valid(user);
    if(validation.hasErrors()) {
      throw new ValidationException(validation.errors());
    }
    user.insert();
    UserProfile user_profile = new UserProfile(user,Profile.findByType(ProfileType.INTERNSHIP));
    user_profile.insert();
    response.status = StatusCode.CREATED;
    Map map = new HashMap();
    map.put("id", user.id);
    String url = Router.reverse("api.Users.get", map).url;// GET /clients/1541
    response.setHeader("location", url);
View Full Code Here

    validation.valid(familiar);
    if(validation.hasErrors()) {
      throw new ValidationException(validation.errors());
    }
    familiar.insert();
    UserProfile user_profile = new UserProfile(familiar,
        Profile.findByType(Profile.ProfileType.FAMILIAR));
    user_profile.insert();
    InternshipFamiliar internshipFamiliar = new InternshipFamiliar(internal, familiar);
    internshipFamiliar.insert();
    response.status = StatusCode.CREATED;
    Map map = new HashMap();
    map.put("id", familiar.id);
View Full Code Here

TOP

Related Classes of models.UserProfile

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.