Search in sources :

Example 86 with CloseableCalloutWindowController

use of org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController in project OpenOLAT by OpenOLAT.

the class GTACoachedGroupGradingController method doComment.

private void doComment(UserRequest ureq, AssessmentRow row) {
    removeAsListenerAndDispose(commentCalloutCtrl);
    VelocityContainer descriptionVC = createVelocityContainer("comment_readonly_callout");
    descriptionVC.contextPut("comment", row.getComment());
    commentCalloutCtrl = new CloseableCalloutWindowController(ureq, getWindowControl(), descriptionVC, row.getCommentTooltipLink().getFormDispatchId(), "", true, "");
    listenTo(commentCalloutCtrl);
    commentCalloutCtrl.activate();
}
Also used : CloseableCalloutWindowController(org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController) VelocityContainer(org.olat.core.gui.components.velocity.VelocityContainer)

Example 87 with CloseableCalloutWindowController

use of org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController in project OpenOLAT by OpenOLAT.

the class CourseReminderListController method doOpenTools.

private void doOpenTools(UserRequest ureq, ReminderRow row, FormLink link) {
    removeAsListenerAndDispose(toolsCtrl);
    removeAsListenerAndDispose(toolsCalloutCtrl);
    toolsCtrl = new ToolsController(ureq, getWindowControl(), row);
    listenTo(toolsCtrl);
    toolsCalloutCtrl = new CloseableCalloutWindowController(ureq, getWindowControl(), toolsCtrl.getInitialComponent(), link.getFormDispatchId(), "", true, "");
    listenTo(toolsCalloutCtrl);
    toolsCalloutCtrl.activate();
}
Also used : CloseableCalloutWindowController(org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController)

Example 88 with CloseableCalloutWindowController

use of org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController in project OpenOLAT by OpenOLAT.

the class CorrectionIdentityInteractionsController method doOverrideScore.

private void doOverrideScore(UserRequest ureq) {
    if (overrideScoreCtrl != null)
        return;
    overrideScoreCtrl = new OverrideScoreController(ureq, getWindowControl());
    listenTo(overrideScoreCtrl);
    overrideScoreCalloutCtrl = new CloseableCalloutWindowController(ureq, getWindowControl(), overrideScoreCtrl.getInitialComponent(), overrideScoreButton.getFormDispatchId(), "", true, "o_assessmentitem_scoring_override_window");
    listenTo(overrideScoreCalloutCtrl);
    overrideScoreCalloutCtrl.activate();
}
Also used : CloseableCalloutWindowController(org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController)

Example 89 with CloseableCalloutWindowController

use of org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController in project OpenOLAT by OpenOLAT.

the class ProjectListController method activateUserController.

private void activateUserController(final Project projectAt, UserRequest urequest, TableEvent tableEvent) {
    if (projectAt.getProjectLeaders().isEmpty()) {
        this.showInfo("show.info.no.project.leader");
    } else if (projectAt.getProjectLeaders().size() > 1) {
        VelocityContainer identityVC = createVelocityContainer("identityCallout");
        List<Identity> allIdents = projectAt.getProjectLeaders();
        ArrayList<Link> identLinks = new ArrayList<Link>(allIdents.size());
        for (Identity identity : allIdents) {
            String last = identity.getUser().getProperty(UserConstants.LASTNAME, getLocale());
            String first = identity.getUser().getProperty(UserConstants.FIRSTNAME, getLocale());
            String linkName = last + " " + first;
            Link idLink = LinkFactory.createCustomLink(linkName, OPEN_IDENTITY_CMD, linkName, Link.NONTRANSLATED, identityVC, this);
            idLink.setUserObject(identity);
            identLinks.add(idLink);
        }
        identityVC.contextPut("identLinks", identLinks);
        int row = tableEvent.getRowId();
        String targetDomID = ProjectManagerColumnRenderer.PROJECTMANAGER_COLUMN_ROW_IDENT + row;
        String title = translate("projectlist.callout.title", projectAt.getTitle());
        removeAsListenerAndDispose(calloutCtrl);
        calloutCtrl = new CloseableCalloutWindowController(urequest, getWindowControl(), identityVC, targetDomID, title, true, null);
        calloutCtrl.activate();
        listenTo(calloutCtrl);
    } else if (projectAt.getProjectLeaders().size() == 1) {
        // no callout, if its only one user
        Identity leader = projectAt.getProjectLeaders().get(0);
        openUserInPopup(urequest, leader);
    }
}
Also used : ArrayList(java.util.ArrayList) CloseableCalloutWindowController(org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController) ArrayList(java.util.ArrayList) List(java.util.List) Identity(org.olat.core.id.Identity) Link(org.olat.core.gui.components.link.Link) VelocityContainer(org.olat.core.gui.components.velocity.VelocityContainer)

Example 90 with CloseableCalloutWindowController

use of org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController in project OpenOLAT by OpenOLAT.

the class TeacherRollCallController method doCalloutReasonAbsence.

private void doCalloutReasonAbsence(UserRequest ureq, String elementId, TeacherRollCallRow row) {
    boolean canEdit = secCallback.canEdit() && secCallback.canEditAuthorizedAbsences();
    reasonCtrl = new ReasonController(ureq, getWindowControl(), row, canEdit);
    listenTo(reasonCtrl);
    reasonCalloutCtrl = new CloseableCalloutWindowController(ureq, getWindowControl(), reasonCtrl.getInitialComponent(), elementId, "", true, "");
    listenTo(reasonCalloutCtrl);
    reasonCalloutCtrl.activate();
}
Also used : CloseableCalloutWindowController(org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController)

Aggregations

CloseableCalloutWindowController (org.olat.core.gui.control.generic.closablewrapper.CloseableCalloutWindowController)122 VelocityContainer (org.olat.core.gui.components.velocity.VelocityContainer)12 FormLink (org.olat.core.gui.components.form.flexible.elements.FormLink)8 ArrayList (java.util.ArrayList)6 List (java.util.List)6 Component (org.olat.core.gui.components.Component)6 Link (org.olat.core.gui.components.link.Link)6 Identity (org.olat.core.id.Identity)6 RepositoryEntry (org.olat.repository.RepositoryEntry)6 RepositoryEntrySmallDetailsController (org.olat.repository.ui.author.RepositoryEntrySmallDetailsController)6 UserSearchController (org.olat.admin.user.UserSearchController)4 CalloutSettings (org.olat.core.gui.control.generic.closablewrapper.CalloutSettings)4 NamingException (javax.naming.NamingException)2 LdapContext (javax.naming.ldap.LdapContext)2 KalendarRenderWrapper (org.olat.commons.calendar.ui.components.KalendarRenderWrapper)2 UserRequest (org.olat.core.gui.UserRequest)2 Choice (org.olat.core.gui.components.choice.Choice)2 FormToggle (org.olat.core.gui.components.form.flexible.elements.FormToggle)2 SingleSelection (org.olat.core.gui.components.form.flexible.elements.SingleSelection)2 JSAndCSSComponent (org.olat.core.gui.components.htmlheader.jscss.JSAndCSSComponent)2