Package com.uphea.domain

Examples of com.uphea.domain.UserUid


   */
  public UserUid createUidForUser(User user) {

    Long userId = user.getId();

    UserUid uid = appDao.findById(UserUid.class, userId);
    if (uid != null) {
      uid.setUid(generateNewUid());
      appDao.updateProperty(uid, "uid", uid.getUid());
    } else {
      uid = new UserUid();
      uid.setId(userId);
      uid.setUid(generateNewUid());
      // ID is not autogenerated, therefore it is created manually.
      // Hence, we are calling save(), instead store().
      appDao.save(uid);
    }
    return uid;
View Full Code Here


   */
  public Long findUserIdByUid(String uidValue) {
    if (uidValue == null) {
      return null;
    }
    UserUid uid = appDao.findOneByProperty(UserUid.class, "uid", uidValue);
    if (uid == null) {
      return null;
    }
    return uid.getId();
  }
View Full Code Here

  public String execute() {
    if ((captcha != null) && captcha.isCorrect(captchaAnswer)) {
      User user = userService.findUserByEmail(email);

      if (user != null) {
        UserUid uid = userUidService.createUidForUser(user);
        emailBuilder.createLostPasswordMessage(user, uid);
      }

      return REDIRECT + alias(this, "ok");
    }
View Full Code Here

TOP

Related Classes of com.uphea.domain.UserUid

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.