Search in sources :

Example 56 with WindowControl

use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.

the class OverviewRepositoryListController method doOpenMark.

private RepositoryEntryListController doOpenMark(UserRequest ureq) {
    cleanUp();
    SearchMyRepositoryEntryViewParams searchParams = new SearchMyRepositoryEntryViewParams(getIdentity(), ureq.getUserSession().getRoles());
    searchParams.setMarked(Boolean.TRUE);
    OLATResourceable ores = OresHelper.createOLATResourceableInstance("Favorits", 0l);
    ThreadLocalUserActivityLogger.addLoggingResourceInfo(LoggingResourceable.wrapBusinessPath(ores));
    WindowControl bwControl = BusinessControlFactory.getInstance().createBusinessWindowControl(ores, null, getWindowControl());
    markedStackPanel = new BreadcrumbedStackedPanel("mrkstack", getTranslator(), this);
    markedCtrl = new RepositoryEntryListController(ureq, bwControl, searchParams, true, false, "marked", markedStackPanel);
    markedStackPanel.pushController(translate("search.mark"), markedCtrl);
    listenTo(markedCtrl);
    currentCtrl = markedCtrl;
    favoritDirty = false;
    addToHistory(ureq, markedCtrl);
    mainVC.put("segmentCmp", markedStackPanel);
    return markedCtrl;
}
Also used : OLATResourceable(org.olat.core.id.OLATResourceable) SearchMyRepositoryEntryViewParams(org.olat.repository.model.SearchMyRepositoryEntryViewParams) WindowControl(org.olat.core.gui.control.WindowControl) BreadcrumbedStackedPanel(org.olat.core.gui.components.stack.BreadcrumbedStackedPanel)

Example 57 with WindowControl

use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.

the class RepositoryEntryListController method doOpenDetails.

protected void doOpenDetails(UserRequest ureq, RepositoryEntryRow row) {
    // to be more consistent: course members see info page within the course, non-course members see it outside the course
    if (row.isMember()) {
        doOpen(ureq, row, "[Infos:0]");
    } else {
        removeAsListenerAndDispose(detailsCtrl);
        OLATResourceable ores = OresHelper.createOLATResourceableInstance("Infos", 0l);
        WindowControl bwControl = BusinessControlFactory.getInstance().createBusinessWindowControl(ores, null, getWindowControl());
        RepositoryEntry entry = repositoryService.loadByKey(row.getKey());
        if (entry == null) {
            showWarning("repositoryentry.not.existing");
        } else {
            detailsCtrl = new RepositoryEntryDetailsController(ureq, bwControl, entry, row, false);
            listenTo(detailsCtrl);
            addToHistory(ureq, detailsCtrl);
            String displayName = row.getDisplayName();
            stackPanel.pushController(displayName, detailsCtrl);
        }
    }
}
Also used : OLATResourceable(org.olat.core.id.OLATResourceable) RepositoryEntry(org.olat.repository.RepositoryEntry) WindowControl(org.olat.core.gui.control.WindowControl)

Example 58 with WindowControl

use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.

the class RepositoryEntryRuntimeController method doMembers.

protected Activateable2 doMembers(UserRequest ureq) {
    if (!reSecurity.isEntryAdmin())
        return null;
    WindowControl bwControl = getSubWindowControl("MembersMgmt");
    RepositoryMembersController ctrl = new RepositoryMembersController(ureq, addToHistory(ureq, bwControl), toolbarPanel, re);
    listenTo(ctrl);
    membersEditController = pushController(ureq, translate("details.members"), ctrl);
    currentToolCtr = membersEditController;
    setActiveTool(membersLink);
    return membersEditController;
}
Also used : WindowControl(org.olat.core.gui.control.WindowControl) RepositoryMembersController(org.olat.repository.ui.author.RepositoryMembersController)

Example 59 with WindowControl

use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.

the class RepositoryEntryRuntimeController method doEditSettings.

/**
 * Open the editor for all repository entry metadata, access control...
 * @param ureq
 */
protected void doEditSettings(UserRequest ureq) {
    if (!reSecurity.isEntryAdmin())
        return;
    WindowControl bwControl = getSubWindowControl("Settings");
    RepositoryEntry refreshedEntry = loadRepositoryEntry();
    RepositoryEditDescriptionController ctrl = new RepositoryEditDescriptionController(ureq, addToHistory(ureq, bwControl), refreshedEntry);
    listenTo(ctrl);
    descriptionCtrl = pushController(ureq, translate("settings.editor"), ctrl);
    currentToolCtr = descriptionCtrl;
    setActiveTool(editDescriptionLink);
}
Also used : RepositoryEntry(org.olat.repository.RepositoryEntry) RepositoryEditDescriptionController(org.olat.repository.ui.author.RepositoryEditDescriptionController) WindowControl(org.olat.core.gui.control.WindowControl)

Example 60 with WindowControl

use of org.olat.core.gui.control.WindowControl in project OpenOLAT by OpenOLAT.

the class RepositoryEntryRuntimeController method doCatalog.

/**
 * Internal helper to initiate the add to catalog workflow
 * @param ureq
 */
protected void doCatalog(UserRequest ureq) {
    if (!reSecurity.isEntryAdmin())
        return;
    popToRoot(ureq).cleanUp();
    WindowControl bwControl = getSubWindowControl("Catalog");
    catalogCtlr = new CatalogSettingsController(ureq, addToHistory(ureq, bwControl), toolbarPanel, re);
    listenTo(catalogCtlr);
    catalogCtlr.initToolbar();
    currentToolCtr = catalogCtlr;
    setActiveTool(catalogLink);
}
Also used : CatalogSettingsController(org.olat.repository.ui.author.CatalogSettingsController) WindowControl(org.olat.core.gui.control.WindowControl)

Aggregations

WindowControl (org.olat.core.gui.control.WindowControl)628 OLATResourceable (org.olat.core.id.OLATResourceable)300 UserRequest (org.olat.core.gui.UserRequest)136 Controller (org.olat.core.gui.control.Controller)70 ControllerCreator (org.olat.core.gui.control.creator.ControllerCreator)68 RepositoryEntry (org.olat.repository.RepositoryEntry)68 StepsMainRunController (org.olat.core.gui.control.generic.wizard.StepsMainRunController)64 ContextEntry (org.olat.core.id.context.ContextEntry)58 Step (org.olat.core.gui.control.generic.wizard.Step)56 StepRunnerCallback (org.olat.core.gui.control.generic.wizard.StepRunnerCallback)56 StepsRunContext (org.olat.core.gui.control.generic.wizard.StepsRunContext)56 BusinessControl (org.olat.core.id.context.BusinessControl)56 LayoutMain3ColsController (org.olat.core.commons.fullWebApp.LayoutMain3ColsController)46 ArrayList (java.util.ArrayList)42 Identity (org.olat.core.id.Identity)38 StateSite (org.olat.core.id.context.StateSite)32 PopupBrowserWindow (org.olat.core.gui.control.generic.popup.PopupBrowserWindow)28 AssertException (org.olat.core.logging.AssertException)24 QuestionsController (org.olat.modules.qpool.ui.QuestionsController)22 List (java.util.List)20