Search in sources :

Example 21 with NodeEditController

use of org.olat.course.editor.NodeEditController in project OpenOLAT by OpenOLAT.

the class IQTESTCourseNode method createEditController.

/**
 * @see org.olat.course.nodes.CourseNode#createEditController(org.olat.core.gui.UserRequest,
 *      org.olat.core.gui.control.WindowControl, org.olat.course.ICourse)
 */
@Override
public TabbableController createEditController(UserRequest ureq, WindowControl wControl, BreadcrumbPanel stackPanel, ICourse course, UserCourseEnvironment euce) {
    updateModuleConfigDefaults(false);
    TabbableController childTabCntrllr = new IQEditController(ureq, wControl, stackPanel, course, this, euce);
    CourseNode chosenNode = course.getEditorTreeModel().getCourseNode(euce.getCourseEditorEnv().getCurrentCourseNodeId());
    return new NodeEditController(ureq, wControl, course.getEditorTreeModel(), course, chosenNode, euce, childTabCntrllr);
}
Also used : NodeEditController(org.olat.course.editor.NodeEditController) IQEditController(org.olat.course.nodes.iq.IQEditController) TabbableController(org.olat.core.gui.control.generic.tabbable.TabbableController)

Example 22 with NodeEditController

use of org.olat.course.editor.NodeEditController in project openolat by klemens.

the class SPEditController method event.

/**
 * @see org.olat.core.gui.control.DefaultController#event(org.olat.core.gui.UserRequest, org.olat.core.gui.control.Controller, org.olat.core.gui.control.Event)
 */
@Override
public void event(UserRequest urequest, Controller source, Event event) {
    if (source instanceof NodeEditController) {
        if (combiLinkCtr != null && combiLinkCtr.isDoProposal()) {
            combiLinkCtr.setRelFilePath(CourseEditorHelper.createUniqueRelFilePathFromShortTitle(courseNode, courseFolderBaseContainer));
        }
    } else if (source == accessibilityCondContr) {
        if (event == Event.CHANGED_EVENT) {
            Condition cond = accessibilityCondContr.getCondition();
            courseNode.setPreConditionAccess(cond);
            fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
        }
    } else if (source == deliveryOptionsCtrl) {
        if (event == Event.DONE_EVENT || event == Event.CHANGED_EVENT) {
            DeliveryOptions config = deliveryOptionsCtrl.getDeliveryOptions();
            if (config != null) {
                moduleConfiguration.set(CONFIG_KEY_DELIVERYOPTIONS, config);
                fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
            }
        }
    } else if (source == combiLinkCtr) {
        if (event == Event.DONE_EVENT) {
            String relPath = VFSManager.getRelativeItemPath(combiLinkCtr.getFile(), courseFolderBaseContainer, null);
            combiLinkCtr.setEditable(hasEditRights(relPath));
            moduleConfiguration.set(CONFIG_KEY_FILE, relPath);
            fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
            if (!myTabbedPane.containsTab(deliveryOptionsCtrl.getInitialComponent())) {
                myTabbedPane.addTab(translate(PANE_TAB_DELIVERYOPTIONS), deliveryOptionsCtrl.getInitialComponent());
            }
            myContent.contextPut("editorEnabled", combiLinkCtr.isEditorEnabled());
        }
    } else if (source == securitySettingForm) {
        if (event == Event.DONE_EVENT) {
            boolean allowRelativeLinks = securitySettingForm.getAllowRelativeLinksConfig();
            moduleConfiguration.set(CONFIG_KEY_ALLOW_RELATIVE_LINKS, allowRelativeLinks);
            moduleConfiguration.set(CONFIG_KEY_ALLOW_COACH_EDIT, securitySettingForm.getAllowCoachEditConfig());
            combiLinkCtr.setAllowEditorRelativeLinks(allowRelativeLinks);
            fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
        }
    }
}
Also used : Condition(org.olat.course.condition.Condition) NodeEditController(org.olat.course.editor.NodeEditController) DeliveryOptions(org.olat.core.gui.control.generic.iframe.DeliveryOptions)

Example 23 with NodeEditController

use of org.olat.course.editor.NodeEditController in project openolat by klemens.

the class InfoCourseNode method createEditController.

@Override
public TabbableController createEditController(UserRequest ureq, WindowControl wControl, BreadcrumbPanel stackPanel, ICourse course, UserCourseEnvironment euce) {
    InfoCourseNodeEditController childTabCntrllr = new InfoCourseNodeEditController(ureq, wControl, getModuleConfiguration(), this, course, euce);
    CourseNode chosenNode = course.getEditorTreeModel().getCourseNode(euce.getCourseEditorEnv().getCurrentCourseNodeId());
    return new NodeEditController(ureq, wControl, course.getEditorTreeModel(), course, chosenNode, euce, childTabCntrllr);
}
Also used : InfoCourseNodeEditController(org.olat.course.nodes.info.InfoCourseNodeEditController) NodeEditController(org.olat.course.editor.NodeEditController) InfoCourseNodeEditController(org.olat.course.nodes.info.InfoCourseNodeEditController)

Example 24 with NodeEditController

use of org.olat.course.editor.NodeEditController in project openolat by klemens.

the class MembersCourseNode method createEditController.

@Override
public TabbableController createEditController(UserRequest ureq, WindowControl wControl, BreadcrumbPanel stackPanel, ICourse course, UserCourseEnvironment euce) {
    updateModuleConfigDefaults(false);
    MembersCourseNodeEditController childTabCntrllr = new MembersCourseNodeEditController(ureq, wControl, euce, this.getModuleConfiguration());
    CourseNode chosenNode = course.getEditorTreeModel().getCourseNode(euce.getCourseEditorEnv().getCurrentCourseNodeId());
    return new NodeEditController(ureq, wControl, course.getEditorTreeModel(), course, chosenNode, euce, childTabCntrllr);
}
Also used : MembersCourseNodeEditController(org.olat.course.nodes.members.MembersCourseNodeEditController) NodeEditController(org.olat.course.editor.NodeEditController) MembersCourseNodeEditController(org.olat.course.nodes.members.MembersCourseNodeEditController) InfoCourseNodeEditController(org.olat.course.nodes.info.InfoCourseNodeEditController)

Example 25 with NodeEditController

use of org.olat.course.editor.NodeEditController in project openolat by klemens.

the class ProjectBrokerCourseNode method createEditController.

/**
 * @see org.olat.course.nodes.CourseNode#createEditController(org.olat.core.gui.UserRequest,
 *      org.olat.core.gui.control.WindowControl, org.olat.course.ICourse)
 */
@Override
public TabbableController createEditController(UserRequest ureq, WindowControl wControl, BreadcrumbPanel stackPanel, ICourse course, UserCourseEnvironment euce) {
    updateModuleConfigDefaults(false);
    ProjectBrokerCourseEditorController childTabCntrllr = ProjectBrokerControllerFactory.createCourseEditController(ureq, wControl, course, euce, this);
    CourseNode chosenNode = course.getEditorTreeModel().getCourseNode(euce.getCourseEditorEnv().getCurrentCourseNodeId());
    NodeEditController editController = new NodeEditController(ureq, wControl, course.getEditorTreeModel(), course, chosenNode, euce, childTabCntrllr);
    editController.addControllerListener(childTabCntrllr);
    return editController;
}
Also used : NodeEditController(org.olat.course.editor.NodeEditController) ProjectBrokerCourseEditorController(org.olat.course.nodes.projectbroker.ProjectBrokerCourseEditorController)

Aggregations

NodeEditController (org.olat.course.editor.NodeEditController)78 TabbableController (org.olat.core.gui.control.generic.tabbable.TabbableController)10 AbstractAccessableCourseNode (org.olat.course.nodes.AbstractAccessableCourseNode)8 CourseNode (org.olat.course.nodes.CourseNode)8 IQEditController (org.olat.course.nodes.iq.IQEditController)6 Condition (org.olat.course.condition.Condition)4 FeedNodeEditController (org.olat.course.nodes.feed.FeedNodeEditController)4 InfoCourseNodeEditController (org.olat.course.nodes.info.InfoCourseNodeEditController)4 ChecklistEditController (de.bps.course.nodes.cl.ChecklistEditController)2 DENEditController (de.bps.course.nodes.den.DENEditController)2 LLEditController (de.bps.course.nodes.ll.LLEditController)2 NoProviderController (de.bps.course.nodes.vc.NoProviderController)2 VCConfiguration (de.bps.course.nodes.vc.VCConfiguration)2 VCEditController (de.bps.course.nodes.vc.VCEditController)2 VCProvider (de.bps.course.nodes.vc.provider.VCProvider)2 List (java.util.List)2 DeliveryOptions (org.olat.core.gui.control.generic.iframe.DeliveryOptions)2 TabbableDefaultController (org.olat.core.gui.control.generic.tabbable.TabbableDefaultController)2 LTIEditController (org.olat.course.nodes.basiclti.LTIEditController)2 BCCourseNodeEditController (org.olat.course.nodes.bc.BCCourseNodeEditController)2