Package org.olat.course.condition

Examples of org.olat.course.condition.ConditionEditController


   
    CourseGroupManager groupMgr = course.getCourseEnvironment().getCourseGroupManager();
    CourseEditorTreeModel editorModel = course.getEditorTreeModel();
    //Accessibility precondition
    Condition accessCondition = courseNode.getPreConditionAccess();
    accessibilityCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, accessCondition,
        "accessabilityConditionForm", AssessmentHelper.getAssessableNodes(editorModel, spCourseNode), euce);   
    this.listenTo(accessibilityCondContr);
   
  }
View Full Code Here


    CourseGroupManager groupMgr = course.getCourseEnvironment().getCourseGroupManager();
    CourseEditorTreeModel editorModel = course.getEditorTreeModel();

    // Moderator precondition
    Condition moderatorCondition = node.getPreConditionModerator();
    moderatroCtr = new ConditionEditController(ureq, getWindowControl(), groupMgr, moderatorCondition, "moderatorConditionForm",
        AssessmentHelper.getAssessableNodes(editorModel, node), uce);
    this.listenTo(moderatroCtr);
    accessVC.put("moderatorCondition", moderatroCtr.getInitialComponent());

    // Poster precondition
    Condition posterCondition = node.getPreConditionPoster();
    posterCtr = new ConditionEditController(ureq, getWindowControl(), groupMgr, posterCondition, "posterConditionForm", AssessmentHelper
        .getAssessableNodes(editorModel, node), uce);
    this.listenTo(posterCtr);
    accessVC.put("posterCondition", posterCtr.getInitialComponent());

    // Reader precondition
    Condition readerCondition = node.getPreConditionReader();
    readerCtr = new ConditionEditController(ureq, getWindowControl(), groupMgr, readerCondition, "readerConditionForm", AssessmentHelper
        .getAssessableNodes(editorModel, node), uce);
    this.listenTo(readerCtr);
    accessVC.put("readerCondition", readerCtr.getInitialComponent());

    // Podcast tab. Embed the actual podcast learning contentVC into the
View Full Code Here

    // Find assessable children nodes
    assessableChildren = AssessmentHelper.getAssessableNodes(editorModel, stNode);

    // Accessibility precondition
    Condition accessCondition = stNode.getPreConditionAccess();
    accessibilityCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, accessCondition, "accessabilityConditionForm",
        assessableChildren, euce);   
    this.listenTo(accessibilityCondContr);

    ScoreCalculator scoreCalc = stNode.getScoreCalculator();
    if (scoreCalc != null) {
View Full Code Here

       
    accessabiliryContent = this.createVelocityContainer("edit");

    // Uploader precondition
    Condition uploadCondition = bcNode.getPreConditionUploaders();
    uploaderCondContr = new ConditionEditController(ureq, getWindowControl(), course.getCourseEnvironment().getCourseGroupManager(),
        uploadCondition, "uploaderConditionForm", AssessmentHelper
            .getAssessableNodes(course.getEditorTreeModel(), bcNode), euce);   
    this.listenTo(uploaderCondContr);
    accessabiliryContent.put("uploadCondition", uploaderCondContr.getInitialComponent());

    // Uploader precondition
    Condition downloadCondition = bcNode.getPreConditionDownloaders();
    downloaderCondContr = new ConditionEditController(ureq, getWindowControl(), course.getCourseEnvironment().getCourseGroupManager(),
        downloadCondition, "downloadConditionForm", AssessmentHelper
            .getAssessableNodes(course.getEditorTreeModel(), bcNode), euce);   
    this.listenTo(downloaderCondContr);
    accessabiliryContent.put("downloadCondition", downloaderCondContr.getInitialComponent());
   
View Full Code Here

        .getPackageName(MSCourseNodeEditController.class), ureq.getLocale()));
    setTranslator(newTranslator);
   
    accessabilityVC = this.createVelocityContainer("edit");
    // Task precondition
    taskConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionTask(), "taskConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);   
    this.listenTo(taskConditionC);
    if (((Boolean) config.get(TACourseNode.CONF_TASK_ENABLED)).booleanValue()) accessabilityVC.put("taskCondition", taskConditionC
        .getInitialComponent());

    // DropBox precondition
    dropConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionDrop(), "dropConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);   
    this.listenTo(dropConditionC);
    Boolean hasDropboxValue = ((Boolean) config.get(TACourseNode.CONF_DROPBOX_ENABLED)!=null) ? (Boolean) config.get(TACourseNode.CONF_DROPBOX_ENABLED) : false;
    if (hasDropboxValue) accessabilityVC.put("dropCondition", dropConditionC.getInitialComponent());
       
    //returnbox precondition - use dropbox condition if none defined for returnbox
    Condition dropboxCondition = node.getConditionDrop();   
    Condition returnboxCondition = node.getConditionReturnbox();
    if(dropboxCondition!=null && returnboxCondition!= null && returnboxCondition.getConditionExpression()==null) {
      //old courses: use ConditionExpression from dropbox if none defined for returnbox     
      returnboxCondition = dropboxCondition;
      returnboxCondition.setConditionId(TACourseNode.ACCESS_RETURNBOX);
      node.setConditionReturnbox(returnboxCondition);     
    }
    returnboxConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, returnboxCondition, "returnboxConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);
    this.listenTo(returnboxConditionC);
    Object returnBoxConf = config.get(TACourseNode.CONF_RETURNBOX_ENABLED);
    //use the dropbox config if none specified for the return box
    boolean returnBoxEnabled = (returnBoxConf !=null) ? ((Boolean) returnBoxConf).booleanValue() : hasDropboxValue;
    if (returnBoxEnabled) accessabilityVC.put("returnboxCondition", returnboxConditionC.getInitialComponent());

    // Scoring precondition
    scoringConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionScoring(), "scoringConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);   
    this.listenTo(scoringConditionC);
    if (((Boolean) config.get(TACourseNode.CONF_SCORING_ENABLED)).booleanValue()) accessabilityVC.put("scoringCondition", scoringConditionC
        .getInitialComponent());

    // SolutionFolder precondition
    solutionConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionSolution(),
        "solutionConditionForm", AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);   
    this.listenTo(solutionConditionC);
    if (((Boolean) config.get(TACourseNode.CONF_SOLUTION_ENABLED)).booleanValue()) accessabilityVC.put("solutionCondition", solutionConditionC
        .getInitialComponent());
   
View Full Code Here

   
    Component fcContent = fccecontr.getInitialComponent();
    myContent.put("filechoosecreateedit", fcContent);
   
    Condition accessCondition = courseNode.getPreConditionAccess();
    accessibilityCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, accessCondition, "accessabilityConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), courseNode),euce);   
    this.listenTo(accessibilityCondContr);

    main.setContent(myContent);
    // not needed for tabbledController: setInitialComponent(main);
View Full Code Here

    myContent = this.createVelocityContainer("edit");
    doFormInit(ureq);

    // Accessibility precondition
    Condition accessCondition = courseNode.getPreConditionAccess();
    accessibilityCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, accessCondition, "accessabilityConditionForm",
        AssessmentHelper.getAssessableNodes(courseP.getEditorTreeModel(), enCourseNode), euceP);   
    this.listenTo(accessibilityCondContr);

    // not needed: setInitialComponent(myContent) since tabbable controller
  }
View Full Code Here

    editAccessVc = this.createVelocityContainer("edit_access");
    CourseGroupManager groupMgr = course.getCourseEnvironment().getCourseGroupManager();
    CourseEditorTreeModel editorModel = course.getEditorTreeModel();
    // Accessibility precondition
    Condition accessCondition = wikiCourseNode.getPreConditionAccess();
    accessCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, accessCondition, "accessConditionForm",
        AssessmentHelper.getAssessableNodes(editorModel, wikiCourseNode), euce);   
    this.listenTo(accessCondContr);
    editAccessVc.put("readerCondition", accessCondContr.getInitialComponent());
   
    //wiki read / write preconditions
    Condition editCondition = wikiCourseNode.getPreConditionEdit();
    editCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, editCondition, "editConditionForm", AssessmentHelper
        .getAssessableNodes(editorModel, wikiCourseNode), euce);   
    this.listenTo(editCondContr);
    editAccessVc.put("editCondition", editCondContr.getInitialComponent());
   
View Full Code Here

    CourseGroupManager groupMgr = course.getCourseEnvironment().getCourseGroupManager();
    CourseEditorTreeModel editorModel = course.getEditorTreeModel();
    // Reader precondition
    Condition readerCondition = courseNode.getPreConditionReader();
    // TODO:gs:a getAssessableNodes ist der dialog node assessable oder nicht?
    readerCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, readerCondition, "readerConditionForm",
        AssessmentHelper.getAssessableNodes(editorModel, courseNode), userCourseEnv);   
    this.listenTo(readerCondContr);
    accessContent.put("readerCondition", readerCondContr.getInitialComponent());

    // Poster precondition
    Condition posterCondition = courseNode.getPreConditionPoster();
    posterCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, posterCondition, "posterConditionForm",
        AssessmentHelper.getAssessableNodes(editorModel, courseNode), userCourseEnv);   
    this.listenTo(posterCondContr);
    accessContent.put("posterCondition", posterCondContr.getInitialComponent());

    // Moderator precondition
    Condition moderatorCondition = courseNode.getPreConditionModerator();
    moderatorCondContr = new ConditionEditController(ureq, getWindowControl(), groupMgr, moderatorCondition, "moderatorConditionForm",
        AssessmentHelper.getAssessableNodes(editorModel, courseNode), userCourseEnv);
    //FIXME:gs: why is firing needed here?
    fireEvent(ureq, NodeEditController.NODECONFIG_CHANGED_EVENT);   
    this.listenTo(moderatorCondContr);
    accessContent.put("moderatorCondition", moderatorCondContr.getInitialComponent());
View Full Code Here

    }
 
    // Access
    accessabilityVC = this.createVelocityContainer("edit_condition");
    // DropBox precondition
    dropConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionDrop(), "dropConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);   
    this.listenTo(dropConditionC);
    boolean hasDropboxValue = ((Boolean) config.get(ProjectBrokerCourseNode.CONF_DROPBOX_ENABLED)).booleanValue();
    if (hasDropboxValue) accessabilityVC.put("dropCondition", dropConditionC
        .getInitialComponent());
    // Scoring precondition
    scoringConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionScoring(), "scoringConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);   
    this.listenTo(scoringConditionC);
    if (((Boolean) config.get(ProjectBrokerCourseNode.CONF_SCORING_ENABLED)).booleanValue()) accessabilityVC.put("scoringCondition", scoringConditionC
        .getInitialComponent());
    //returnbox precondition
    returnboxConditionC = new ConditionEditController(ureq, getWindowControl(), groupMgr, node.getConditionReturnbox(), "returnboxConditionForm",
        AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), node), euce);
    this.listenTo(returnboxConditionC);
    Object returnBoxConf = config.get(ProjectBrokerCourseNode.CONF_RETURNBOX_ENABLED);
    //use the dropbox config if none specified for the return box
    boolean returnBoxEnabled = (returnBoxConf !=null) ? ((Boolean) returnBoxConf).booleanValue() : hasDropboxValue;
View Full Code Here

TOP

Related Classes of org.olat.course.condition.ConditionEditController

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.