Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-28578

Completion Activity not working for Wiki

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: Minor
    • Resolution: Duplicate
    • Affects Version/s: 2.0, 2.1
    • Fix Version/s: None
    • Component/s: Activity completion
    • Labels:
      None
    • Testing Instructions:
      Hide
      • Create a course with the 'Completion tracking' => 'Enabled, control via completion and activity settings'
      • Add a wiki activity with 'Completion tracking' => 'Show activity as complete when conditions are met', tick the option 'Student must view this activity to complete it' on 'Require view'
      • Enrol student to the course
      • Log in with the student account
      • open/post/ the wikipedia.

      To check if the activity is marked as complete go to the completion reports on
      course Reports => Activity completion.
      http://moodle/course/report/progress/index.php?course=xx

      The wiki activity should be ticked for the student.

      Show
      Create a course with the 'Completion tracking' => 'Enabled, control via completion and activity settings' Add a wiki activity with 'Completion tracking' => 'Show activity as complete when conditions are met', tick the option 'Student must view this activity to complete it' on 'Require view' Enrol student to the course Log in with the student account open/post/ the wikipedia. To check if the activity is marked as complete go to the completion reports on course Reports => Activity completion. http://moodle/course/report/progress/index.php?course=xx The wiki activity should be ticked for the student.
    • Workaround:
      Hide

      this code fix the problem
      // Update 'viewed' state if required by completion system
      require_once($CFG->libdir . '/completionlib.php');
      $completion = new completion_info($course);
      $completion->set_module_viewed($cm);

      where
      $cm = get_coursemodule_from_id('wiki', $id)
      $course = $DB->get_record('course', array('id' => $cm->course), '*', MUST_EXIST);

      Show
      this code fix the problem // Update 'viewed' state if required by completion system require_once($CFG->libdir . '/completionlib.php'); $completion = new completion_info($course); $completion->set_module_viewed($cm); where $cm = get_coursemodule_from_id('wiki', $id) $course = $DB->get_record('course', array('id' => $cm->course), '*', MUST_EXIST);
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE

      Description

      I have a course with activity completion set on. Added a wiki the completion settings as follows

      • Completion setting: Show activity as complete when conditions are met
      • Require View checkbox is checked (Student must view this activity to complete it)

      When the student views/interacts with the wiki, the wiki activity is not marked as completed.
      It seems that the wiki is the only activity that has not the completion working.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              quen Sam Marshall
              Reporter:
              mmorelos Martha
              Participants:
              Component watchers:
              Sam Marshall, Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Víctor Déniz Falcón
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: