Package org.openmeetings.app.persistence.beans.user

Examples of org.openmeetings.app.persistence.beans.user.Users


        log.debug("appointmentId " + appointmentId);

        Appointment app = AppointmentLogic.getInstance()
            .getAppointMentById(appointmentId);

        Users user = Usermanagement.getInstance().getUserById(users_id);
       
        return AppointmentLogic.getInstance().updateAppointmentByTime(
            appointmentId,
            appointmentstart, appointmentend,
            users_id, baseurl, language_id,
            user.getOmTimeZone().getIcal());
      }
    } catch (Exception err) {
      log.error("[updateAppointment]", err);
      err.printStackTrace();
    }
View Full Code Here


          room.setRoomtype(rt);

          Roommanagement.getInstance().updateRoomObject(room);
        }

        Users user = Usermanagement.getInstance().getUserById(users_id);
       
        return AppointmentLogic.getInstance().updateAppointment(
            appointmentId, appointmentName, appointmentDescription,
            appointmentstart, appointmentend, isDaily, isWeekly,
            isMonthly, isYearly, categoryId, remind, mmClient,
            users_id, baseurl, language_id, false, "",
            user.getOmTimeZone().getIcal());
      }
    } catch (Exception err) {
      log.error("[updateAppointment]", err);
      err.printStackTrace();
    }
View Full Code Here

        Appointment appointment = new Appointment();

        Appointment appStored = AppointmentDaoImpl.getInstance().getAppointmentByRoomId(
                              users_id, room_id);

        Users user = Usermanagement.getInstance().getUserById(users_id);
       
        TimeZone timeZone = TimeZone.getTimeZone(user.getOmTimeZone().getIcal());
       
        Calendar cal = Calendar.getInstance();
        cal.setTimeZone(timeZone);
        int offset = cal.get(Calendar.ZONE_OFFSET) + cal.get(Calendar.DST_OFFSET);
       
View Full Code Here

    assertNotNull("Cann't add appointment", id);
    return ap;
  }

  public Users createUser(int rnd) throws Exception {
    Users users = new Users();
    // add user
    users.setFirstname("firstname" + rnd);
    users.setLastname("lastname" + rnd);
    users.setLogin("login");
    users.setPassword("pass" + rnd);
    users.setLanguage_id(1L);
    Long user_id = userManagement.addUser(users);
    assertTrue("Cann't add user", user_id > 0);
    users = userManagement.getUserByIdAndDeleted(user_id);
    assertNotNull("User should not be null", users);
    return users;
View Full Code Here

        .addUserToOrganisation(new Long(1), organisation_id,
            new Long(1));

    log.error("new organisation_user: " + organisation_usersid);

    Users us = usersDao.getUser(new Long(1));

    log.error(us.getLastname());
    log.error(us.getAdresses().getTown());

    /*
     * for (Iterator it = us.getAdresses().getEmails().iterator();
     * it.hasNext();){ Adresses_Emails addrMails = (Adresses_Emails)
     * it.next(); log.error(addrMails.getMail().getEmail()); }
View Full Code Here

  @Test
  public void testTestLogin(){
    Sessiondata sessionData = mService.getsessiondata();
   
    Users us = (Users) mService.loginUser(sessionData.getSession_id(), username, userpass, false, null, -1L);
   
    assertNotNull("User is unable to login", us);
   
    //mService.getLanguageById(1);
   
View Full Code Here

    return null//unreachable
  }
 
  @Test
  public void getUsersByOrganisationId() {
    Users u = getValidUser();
    Long orgId = u.getOrganisation_users().get(0).getOrganisation().getOrganisation_id();
    List<Users> ul = orgManagement.getUsersByOrganisationId(orgId, 0, 9999, "login", true);
    assertTrue("Default Organisation should contain at least 1 user: " + ul.size(), ul.size() > 0);
   
    Organisation_Users ou = orgManagement.getOrganisation_UserByUserAndOrganisation(u.getUser_id(), orgId);
    assertNotNull("Unable to found [organisation, user] pair - [" + orgId + "," + u.getUser_id() + "]", ou);
  }
View Full Code Here

        if (user_id == null || user_id < 0) {
          return user_id;
        }

        Users user = userManagement.getUserById(user_id);

        // activate the User
        user.setStatus(1);
        user.setUpdatetime(new Date());

        userManagement.updateUser(user);

        return user_id;
View Full Code Here

        if (user_id < 0) {
          return user_id;
        }

        Users user = userManagement.getUserById(user_id);

        // activate the User
        user.setStatus(1);
        user.setUpdatetime(new Date());

        userManagement.updateUser(user);

        return user_id;
View Full Code Here

      Long users_id = sessionManagement.checkSession(SID);
      Long user_level = userManagement.getUserLevelByID(users_id);

      if (authLevelManagement.checkAdminLevel(user_level)) {

        Users testUser = userManagement.getUserByExternalIdAndType(
            externalUserId, externalUserType);

        if (testUser != null) {
          throw new Exception("User does already exist!");
        }

        // This will send no email to the users
        Long user_id = userManagement.registerUserNoEmail(username,
            userpass, lastname, firstname, email, new Date(),
            street, additionalname, fax, zip, states_id, town,
            language_id, "", true, // generate SIP Data if
                        // the config is enabled
            jNameTimeZone);

        if (user_id < 0) {
          return user_id;
        }

        Users user = userManagement.getUserById(user_id);

        // activate the User
        user.setStatus(1);
        user.setUpdatetime(new Date());
        user.setExternalUserId(externalUserId);
        user.setExternalUserType(externalUserType);

        userManagement.updateUser(user);

        return user_id;
View Full Code Here

TOP

Related Classes of org.openmeetings.app.persistence.beans.user.Users

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.