Package org.olat.course.condition

Examples of org.olat.course.condition.Condition


   *      org.olat.core.gui.control.Controller, org.olat.core.gui.control.Event)
   */
  public void event(UserRequest urequest, Controller source, Event event) {
    if (source == accessibilityCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = accessibilityCondContr.getCondition();
        courseNode.setPreConditionAccess(cond);
        fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }
    }else if (source == easyGroupEditCtrllr) {
      //somehting changed in the nodeconfig
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

          fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
        }
      }  // else cancelled repo search
    } else if (source == accessCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = accessCondContr.getCondition();
        wikiCourseNode.setPreConditionAccess(cond);
        fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }else if(event instanceof BGContextEvent) {
        //fired by condition edit controllers if areas / groups created
        //updated other condition controllers -> e.g. change create link to choose
        editCondContr.updateGroupsAndAreasCheck();
      }
    } else if (source == editCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = editCondContr.getCondition();
        wikiCourseNode.setPreConditionEdit(cond);
        fireEvent(urequest, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }else if(event instanceof BGContextEvent) {
        //fired by condition edit controllers if areas / groups created
        //updated other condition controllers -> e.g. change create link to choose
View Full Code Here

    accessContent = this.createVelocityContainer("edit_access");

    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);
View Full Code Here

   *      org.olat.core.gui.components.Component, org.olat.core.gui.control.Event)
   */
  public void event(UserRequest ureq, Controller source, Event event) {
    if (source == readerCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = readerCondContr.getCondition();
        courseNode.setPreConditionReader(cond);
        fireEvent(ureq, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }else if(event instanceof BGContextEvent) {
        //fired by condition edit controllers if areas / groups created
        //updated other condition controllers -> e.g. change create link to choose
        posterCondContr.updateGroupsAndAreasCheck();
        moderatorCondContr.updateGroupsAndAreasCheck();
      }
    } else if (source == posterCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = posterCondContr.getCondition();
        courseNode.setPreConditionPoster(cond);
        fireEvent(ureq, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }else if(event instanceof BGContextEvent) {
        //fired by condition edit controllers if areas / groups created
        //updated other condition controllers -> e.g. change create link to choose
        readerCondContr.updateGroupsAndAreasCheck();
        moderatorCondContr.updateGroupsAndAreasCheck();
      }
    } else if (source == moderatorCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = moderatorCondContr.getCondition();
        courseNode.setPreConditionModerator(cond);
        fireEvent(ureq, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }else if(event instanceof BGContextEvent) {
        //fired by condition edit controllers if areas / groups created
        //updated other condition controllers -> e.g. change create link to choose
View Full Code Here

    this.ores = ores;
    this.courseNode = courseNode;
   
    editVc = this.createVelocityContainer("edit");
   
    Condition accessCondition = courseNode.getPreConditionAccess();
    ICourse course = CourseFactory.loadCourse(ores);
    moduleConfiguration.set(DENCourseNode.CONF_COURSE_ID, course.getResourceableId());
   
    accessibilityCondContr = new ConditionEditController(ureq, wControl, course.getCourseEnvironment().getCourseGroupManager(), accessCondition,
        "accessabilityConditionForm", AssessmentHelper.getAssessableNodes(course.getEditorTreeModel(), courseNode), userCourseEnv);
View Full Code Here

  @Override
  protected void event(UserRequest ureq, Controller source, Event event) {
    if (source == accessibilityCondContr) {
      if (event == Event.CHANGED_EVENT) {
        Condition cond = accessibilityCondContr.getCondition();
        courseNode.setPreConditionAccess(cond);
        fireEvent(ureq, NodeEditController.NODECONFIG_CHANGED_EVENT);
      }
    } else if (source == dateFormContr) {
      moduleConfiguration = dateFormContr.getModuleConfiguration();
View Full Code Here

TOP

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

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.