Examples of addAllIdentites()


Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

  private void doBuddyGroupDelete(UserRequest ureq) {
    // 1) send notification mails to users
    Manager securityManager = ManagerFactory.getManager();
    ContactList owners = new ContactList(translate("userlist.owners.title"));
    List ow = securityManager.getIdentitiesOfSecurityGroup(currBusinessGroup.getOwnerGroup());
    owners.addAllIdentites(ow);
    ContactList participants = new ContactList(translate("userlist.participants.title"));
    participants.addAllIdentites(securityManager.getIdentitiesOfSecurityGroup(currBusinessGroup.getPartipiciantGroup()));
    // check if user is in owner group (could fake link in table)
    if (!PersistenceHelper.listContainsObjectByKey(ow, ureq.getIdentity())) {
      Tracing.logWarn("User tried to delete a group but he was not owner of the group", null, BGMainController.class);
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

          // create e-mail message
          ContactMessage cmsg = new ContactMessage(ureq.getIdentity());

          selectedIdentities = tdm.getIdentities(tmse.getSelection());
          ContactList contacts = new ContactList(translate("mailto.userlist"));
          contacts.addAllIdentites(selectedIdentities);
          cmsg.addEmailTo(contacts);

          // create contact form controller with ContactMessage
          contactCtr = new ContactFormController(ureq, getWindowControl(), false, true, false, false, cmsg);
          listenTo(contactCtr);
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

    Manager securityManager = ManagerFactory.getManager();
    ContactList owners = new ContactList(translate("userlist.owners.title"));
    List ow = securityManager.getIdentitiesOfSecurityGroup(currBusinessGroup.getOwnerGroup());
    owners.addAllIdentites(ow);
    ContactList participants = new ContactList(translate("userlist.participants.title"));
    participants.addAllIdentites(securityManager.getIdentitiesOfSecurityGroup(currBusinessGroup.getPartipiciantGroup()));
    // check if user is in owner group (could fake link in table)
    if (!PersistenceHelper.listContainsObjectByKey(ow, ureq.getIdentity())) {
      Tracing.logWarn("User tried to delete a group but he was not owner of the group", null, BGMainController.class);
      return;
    }
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

    if (sendToChooserForm != null && isAdmin && businessGroup.getWaitingListEnabled().booleanValue()) {
      if (sendToChooserForm.waitingListChecked().equals(BusinessGroupSendToChooserForm.NLS_RADIO_ALL)) {
        waitingListContactList = new ContactList(translate("sendtochooser.form.radio.waitings.all"));
        SecurityGroup waitingList = businessGroup.getWaitingGroup();
        List<Identity> waitingListIdentities = scrtMngr.getIdentitiesOfSecurityGroup(waitingList);
        waitingListContactList.addAllIdentites(waitingListIdentities);
        cmsg.addEmailTo(waitingListContactList);
      } else {
        if (sendToChooserForm.waitingListChecked().equals(BusinessGroupSendToChooserForm.NLS_RADIO_CHOOSE)) {
          waitingListContactList = new ContactList(translate("sendtochooser.form.radio.waitings.choose"));
          SecurityGroup waitingList = businessGroup.getWaitingGroup();
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

            }
            if (!keyIsSelected) {
              changeableWaitingListIdentities.remove(changeableWaitingListIdentities.indexOf(indentity));
            }
          }
          waitingListContactList.addAllIdentites(changeableWaitingListIdentities);
          cmsg.addEmailTo(waitingListContactList);
        }
      }
    }
   
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

    CourseGroupManager cgm = this.userCourseEnv.getCourseEnvironment().getCourseGroupManager();
    List<Identity> coaches = cgm.getCoachesFromLearningGroup(null);
    Set<Identity> coachesWithoutDuplicates = new HashSet<Identity>(coaches);
    coaches = new ArrayList<Identity>(coachesWithoutDuplicates);
    ContactList cl = new ContactList(translate("form.message.chckbx.coaches"));
    cl.addAllIdentites(coaches);
    return cl;
  }

  private ContactList retrieveParticipants() {
    CourseGroupManager cgm = this.userCourseEnv.getCourseEnvironment().getCourseGroupManager();
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

    //FIXME:pb:c docu getParticipantsFromLearningGroup: really duplicates?
    Set<Identity> participantsWithoutDuplicates = new HashSet<Identity>(participiants);
   
    participiants = new ArrayList<Identity>(participantsWithoutDuplicates);
    ContactList cl = new ContactList(translate("form.message.chckbx.partips"));
    cl.addAllIdentites(participiants);
    return cl;

  }

  private ContactList[] retrieveGroups(String csvGroups) {
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

      for (int i = 0; i < mygroups.size(); i++) {
        BusinessGroup bg = mygroups.get(i);
        List<Identity> ids = secManager.getIdentitiesOfSecurityGroup(bg.getPartipiciantGroup());
        ids.addAll(secManager.getIdentitiesOfSecurityGroup(bg.getOwnerGroup()));
        // add all identities to the ContactList
        tmp.addAllIdentites(ids);
      }
      // add the ContactList
      groupsCL.add(tmp);
    }
    // remove duplicates and convert List -> to Array.
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

      for (int i = 0; i < mygroups.size(); i++) {
        BusinessGroup bg = mygroups.get(i);
        List<Identity> ids = secManager.getIdentitiesOfSecurityGroup(bg.getPartipiciantGroup());
        ids.addAll(secManager.getIdentitiesOfSecurityGroup(bg.getOwnerGroup()));
        // add all identities to the ContactList
        tmp.addAllIdentites(ids);
      }
      // add the ContactList
      groupsCL.add(tmp);
    }
    // remove duplicates and convert List -> to Array.
View Full Code Here

Examples of org.olat.core.util.mail.ContactList.addAllIdentites()

  }

  private void doSendMessage(List identities, String mailToName, UserRequest ureq) {
    ContactMessage cmsg = new ContactMessage(ureq.getIdentity());
    ContactList contactList = new ContactList(mailToName);
    contactList.addAllIdentites(identities);
    cmsg.addEmailTo(contactList);
    if (contactCtr != null) contactCtr.dispose();
    contactCtr = new ContactFormController(ureq, getWindowControl(), false, true, false, false, cmsg);
    contactCtr.addControllerListener(this);
    sendMessageVC.put("contactForm", contactCtr.getInitialComponent());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.