Search in sources :

Example 71 with NodeRunConstructionResult

use of org.olat.course.run.navigation.NodeRunConstructionResult in project openolat by klemens.

the class PortfolioCourseNode method createNodeRunConstructionResult.

@Override
public NodeRunConstructionResult createNodeRunConstructionResult(UserRequest ureq, WindowControl wControl, UserCourseEnvironment userCourseEnv, NodeEvaluation ne, String nodecmd) {
    updateModuleConfigDefaults(false);
    Controller controller;
    // OO-136 : do not allow guests to access portfolio task
    Roles roles = ureq.getUserSession().getRoles();
    if (roles.isGuestOnly()) {
        Translator trans = Util.createPackageTranslator(PortfolioCourseNode.class, ureq.getLocale());
        String title = trans.translate("guestnoaccess.title");
        String message = trans.translate("guestnoaccess.message");
        controller = MessageUIFactory.createInfoMessage(ureq, wControl, title, message);
    } else {
        controller = new PortfolioCourseNodeRunController(ureq, wControl, userCourseEnv, this);
    }
    Controller ctrl = TitledWrapperHelper.getWrapper(ureq, wControl, controller, this, "o_ep_icon");
    return new NodeRunConstructionResult(ctrl);
}
Also used : PortfolioCourseNodeRunController(org.olat.course.nodes.portfolio.PortfolioCourseNodeRunController) Translator(org.olat.core.gui.translator.Translator) Roles(org.olat.core.id.Roles) NodeEditController(org.olat.course.editor.NodeEditController) PortfolioCourseNodeRunController(org.olat.course.nodes.portfolio.PortfolioCourseNodeRunController) PortfolioCourseNodeEditController(org.olat.course.nodes.portfolio.PortfolioCourseNodeEditController) TabbableController(org.olat.core.gui.control.generic.tabbable.TabbableController) PortfolioAssessmentDetailsController(org.olat.modules.portfolio.ui.PortfolioAssessmentDetailsController) IdentityListCourseNodeController(org.olat.course.assessment.ui.tool.IdentityListCourseNodeController) AssessmentCourseNodeController(org.olat.course.assessment.ui.tool.AssessmentCourseNodeController) Controller(org.olat.core.gui.control.Controller) PortfolioResultDetailsController(org.olat.course.nodes.portfolio.PortfolioResultDetailsController) NodeRunConstructionResult(org.olat.course.run.navigation.NodeRunConstructionResult)

Example 72 with NodeRunConstructionResult

use of org.olat.course.run.navigation.NodeRunConstructionResult in project openolat by klemens.

the class WikiRunController method createNodeRunConstructionResult.

public NodeRunConstructionResult createNodeRunConstructionResult() {
    TreeModel wikiTreeModel = wikiCtr.getAndUseExternalTree();
    String selNodeId = wikiTreeModel.getRootNode().getChildAt(0).getIdent();
    return new NodeRunConstructionResult(this, wikiTreeModel, selNodeId, wikiCtr);
}
Also used : TreeModel(org.olat.core.gui.components.tree.TreeModel) NodeRunConstructionResult(org.olat.course.run.navigation.NodeRunConstructionResult)

Aggregations

NodeRunConstructionResult (org.olat.course.run.navigation.NodeRunConstructionResult)72 Controller (org.olat.core.gui.control.Controller)62 NodeEditController (org.olat.course.editor.NodeEditController)62 TabbableController (org.olat.core.gui.control.generic.tabbable.TabbableController)60 Translator (org.olat.core.gui.translator.Translator)36 Roles (org.olat.core.id.Roles)36 ConditionEditController (org.olat.course.condition.ConditionEditController)22 AssessmentCourseNodeController (org.olat.course.assessment.ui.tool.AssessmentCourseNodeController)20 RepositoryEntry (org.olat.repository.RepositoryEntry)18 PackageTranslator (org.olat.core.gui.translator.PackageTranslator)12 OLATResourceable (org.olat.core.id.OLATResourceable)10 IdentityListCourseNodeController (org.olat.course.assessment.ui.tool.IdentityListCourseNodeController)8 SubscriptionContext (org.olat.core.commons.services.notifications.SubscriptionContext)6 ICourse (org.olat.course.ICourse)6 AssessmentManager (org.olat.course.assessment.AssessmentManager)6 CourseIQSecurityCallback (org.olat.course.nodes.iq.CourseIQSecurityCallback)6 IQEditController (org.olat.course.nodes.iq.IQEditController)6 RepositoryManager (org.olat.repository.RepositoryManager)6 BusinessControl (org.olat.core.id.context.BusinessControl)4 BusinessControlFactory (org.olat.core.id.context.BusinessControlFactory)4