Package org.apache.openmeetings.db.entity.calendar

Examples of org.apache.openmeetings.db.entity.calendar.MeetingMember


    InputNode listNode1 = root1.getNext(); //HACK to handle external attendee's firstname, lastname, email
    if (listNodeName.equals(listNode.getName())) {
      InputNode item = listNode.getNext();
      InputNode item1 = listNode1.getNext(); //HACK to handle external attendee's firstname, lastname, email
      while (item != null) {
        MeetingMember mm = ser.read(MeetingMember.class, item, false);

        boolean needToSkip1 = true;
        if (mm.getUser() == null) {
          mm.setUser(new User());
        }
        if (mm.getUser().getUser_id() == null) {
          //HACK to handle external attendee's firstname, lastname, email
          boolean contactValid = false;
          do {
            if (Type.contact == mm.getUser().getType() && "firstname".equals(item1.getName())) {
              mm.getUser().setFirstname(item1.getValue());
            }
            if (Type.contact == mm.getUser().getType() && "lastname".equals(item1.getName())) {
              mm.getUser().setLastname(item1.getValue());
            }
            if ("email".equals(item1.getName())) {
              String email = item1.getValue();
              if (mm.getAppointment() != null && mm.getAppointment().getOwner() != null) {
                mm.setUser(usersDao.getContact(email, mm.getAppointment().getOwner()));
              }
              contactValid = true;
            }
            item1 = listNode1.getNext(); //HACK to handle old om_time_zone
          } while (item1 != null && !"meetingmember".equals(item1.getName()));
          if (!contactValid) {
            mm = null;
          }
          needToSkip1 = false;
        }
        if (needToSkip1) {
          do {
            item1 = listNode1.getNext(); //HACK to handle Address inside user
          } while (item1 != null && !"meetingmember".equals(item1.getName()));
        }
        item = listNode.getNext();
        if (mm != null && !mm.isDeleted() && mm.getUser() != null && mm.getAppointment() != null && mm.getAppointment().getId() != null) {
          mm.setId(null);
          list.add(mm);
        }
      }
    }
    return list;
View Full Code Here


          a.getRoom().setNumberOfPartizipants(100L);
          a.getRoom().setAllowUserQuestions(true);
          a.getRoom().setAllowFontStyles(true);
        }
        for (String email : recipients) {
          MeetingMember mm = new MeetingMember();
          mm.setAppointment(a);
          mm.setUser(userDao.getContact(email, users_id));
          a.getMeetingMembers().add(mm);
        }
        a = appointmentDao.update(a, users_id);
        for (MeetingMember mm : a.getMeetingMembers()) {
          User to = mm.getUser();
          Room room = a.getRoom();
         
          //TODO should be reviewed
          if (!to.getUser_id().equals(from.getUser_id())) {
            // One message to the Send
View Full Code Here

      a.setOwner(userDao.get(users_id));
      a.setPasswordProtected(isPasswordProtected);
      a.setPassword(password);
      a.setMeetingMembers(new ArrayList<MeetingMember>());
      for (String singleClient : mmClient) {
        MeetingMember mm = appointmentLogic.getMeetingMember(users_id, languageId, singleClient);
        mm.setAppointment(a);
        a.getMeetingMembers().add(mm);
      }
      return appointmentDao.update(a, users_id).getId();
    } catch (Exception err) {
      log.error("[updateAppointment]", err);
View Full Code Here

    a.setOwner(userDao.get(users_id));
    a.setPasswordProtected(isPasswordProtected);
    a.setPassword(password);
    a.setMeetingMembers(new ArrayList<MeetingMember>());
    for (String singleClient : mmClient) {
      MeetingMember mm = getMeetingMember(users_id, languageId, singleClient);
      mm.setAppointment(a);
      a.getMeetingMembers().add(mm);
    }
    return a;
  }
View Full Code Here

    try {
      return meetingMemberDao.get(Long.valueOf(params[0]));
    } catch (Exception e) {
      //no-op
    }
    MeetingMember mm = new MeetingMember();
    try {
      mm.setUser(userDao.get(Long.valueOf(params[4])));
    } catch (Exception e) {
      //no-op
    }
    if (mm.getUser() == null) {
      mm.setUser(userDao.getContact(params[3], params[1], params[2], langId, params[5], userId));
    }
   
    return mm;
  }
View Full Code Here

    InputNode listNode1 = root1.getNext(); //HACK to handle external attendee's firstname, lastname, email
    if (listNodeName.equals(listNode.getName())) {
      InputNode item = listNode.getNext();
      InputNode item1 = listNode1.getNext(); //HACK to handle external attendee's firstname, lastname, email
      while (item != null) {
        MeetingMember mm = ser.read(MeetingMember.class, item, false);

        boolean needToSkip1 = true;
        if (mm.getUser() == null) {
          mm.setUser(new User());
        }
        if (mm.getUser().getUser_id() == null) {
          //HACK to handle external attendee's firstname, lastname, email
          boolean contactValid = false;
          do {
            if (Type.contact == mm.getUser().getType() && "firstname".equals(item1.getName())) {
              mm.getUser().setFirstname(item1.getValue());
            }
            if (Type.contact == mm.getUser().getType() && "lastname".equals(item1.getName())) {
              mm.getUser().setLastname(item1.getValue());
            }
            if ("email".equals(item1.getName())) {
              String email = item1.getValue();
              if (mm.getAppointment() != null && mm.getAppointment().getOwner() != null) {
                mm.setUser(usersDao.getContact(email, mm.getAppointment().getOwner()));
              }
              contactValid = true;
            }
            item1 = listNode1.getNext(); //HACK to handle old om_time_zone
          } while (item1 != null && !"meetingmember".equals(item1.getName()));
          if (!contactValid) {
            mm = null;
          }
          needToSkip1 = false;
        }
        if (needToSkip1) {
          do {
            item1 = listNode1.getNext(); //HACK to handle Address inside user
          } while (item1 != null && !"meetingmember".equals(item1.getName()));
        }
        item = listNode.getNext();
        if (mm != null && !mm.isDeleted() && mm.getUser() != null && mm.getAppointment() != null && mm.getAppointment().getId() != null) {
          mm.setId(null);
          list.add(mm);
        }
      }
    }
    return list;
View Full Code Here

TOP

Related Classes of org.apache.openmeetings.db.entity.calendar.MeetingMember

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.