Search in sources :

Example 1 with PortfolioInvitationController

use of org.olat.modules.portfolio.ui.PortfolioInvitationController in project openolat by klemens.

the class BinderInvitationContextEntryControllerCreator method createController.

@Override
public Controller createController(List<ContextEntry> ces, UserRequest ureq, WindowControl wControl) {
    if (!ureq.getUserSession().getRoles().isInvitee()) {
        return null;
    }
    Binder binder = getBinderFromContext(ces.get(0));
    BinderConfiguration config = BinderConfiguration.createInvitationConfig();
    List<AccessRights> rights = CoreSpringFactory.getImpl(PortfolioService.class).getAccessRights(binder, ureq.getIdentity());
    BinderSecurityCallback secCallback = BinderSecurityCallbackFactory.getCallbackForInvitation(rights);
    Controller binderCtrl = new PortfolioInvitationController(ureq, wControl, secCallback, binder, config);
    LayoutMain3ColsController layoutCtr = new LayoutMain3ColsController(ureq, wControl, binderCtrl);
    layoutCtr.addDisposableChildController(binderCtrl);
    return layoutCtr;
}
Also used : AccessRights(org.olat.modules.portfolio.model.AccessRights) PortfolioInvitationController(org.olat.modules.portfolio.ui.PortfolioInvitationController) LayoutMain3ColsController(org.olat.core.commons.fullWebApp.LayoutMain3ColsController) PortfolioInvitationController(org.olat.modules.portfolio.ui.PortfolioInvitationController) Controller(org.olat.core.gui.control.Controller) LayoutMain3ColsController(org.olat.core.commons.fullWebApp.LayoutMain3ColsController)

Example 2 with PortfolioInvitationController

use of org.olat.modules.portfolio.ui.PortfolioInvitationController in project OpenOLAT by OpenOLAT.

the class BinderInvitationContextEntryControllerCreator method createController.

@Override
public Controller createController(List<ContextEntry> ces, UserRequest ureq, WindowControl wControl) {
    if (!ureq.getUserSession().getRoles().isInvitee()) {
        return null;
    }
    Binder binder = getBinderFromContext(ces.get(0));
    BinderConfiguration config = BinderConfiguration.createInvitationConfig();
    List<AccessRights> rights = CoreSpringFactory.getImpl(PortfolioService.class).getAccessRights(binder, ureq.getIdentity());
    BinderSecurityCallback secCallback = BinderSecurityCallbackFactory.getCallbackForInvitation(rights);
    Controller binderCtrl = new PortfolioInvitationController(ureq, wControl, secCallback, binder, config);
    LayoutMain3ColsController layoutCtr = new LayoutMain3ColsController(ureq, wControl, binderCtrl);
    layoutCtr.addDisposableChildController(binderCtrl);
    return layoutCtr;
}
Also used : AccessRights(org.olat.modules.portfolio.model.AccessRights) PortfolioInvitationController(org.olat.modules.portfolio.ui.PortfolioInvitationController) LayoutMain3ColsController(org.olat.core.commons.fullWebApp.LayoutMain3ColsController) PortfolioInvitationController(org.olat.modules.portfolio.ui.PortfolioInvitationController) Controller(org.olat.core.gui.control.Controller) LayoutMain3ColsController(org.olat.core.commons.fullWebApp.LayoutMain3ColsController)

Aggregations

LayoutMain3ColsController (org.olat.core.commons.fullWebApp.LayoutMain3ColsController)2 Controller (org.olat.core.gui.control.Controller)2 AccessRights (org.olat.modules.portfolio.model.AccessRights)2 PortfolioInvitationController (org.olat.modules.portfolio.ui.PortfolioInvitationController)2