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

SCORM 2004 Data Model Validation

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 1.9.11
    • 1.9.9
    • SCORM
    • None
    • Debian Linux, Apache, Moodle 1.9.9
    • MySQL
    • MOODLE_19_STABLE
    • MOODLE_19_STABLE
    • Moderate

    Description

      During the hand-in phase of our SCORM 2004 3rd Edition content Moodle presents a "not enough choices: cmi.interactions.N6.correct_responses.N0.pattern" JavaScript alert box and then many consequential ones such as error 408 "Data Model Element Collection Set Out Of Order".

      The first alert box appears within Moodle's validation when setting the CMI data model property cmi.interactions.N6.correct_responses.N0.pattern

      This happens with a multiple choice question (4 choices) with a single correct response ("D").

      elementmodel = "cmi.interactions.n.correct_responses.n.pattern"
      element = "cmi.interactions.N6.correct_responses.N0.pattern"
      value = "D";
      interactiontype = "choice"

      The code presenting the error uses the following logic, given that the nodes array in this case represents the possible correct responses of which a single item is sufficient to fulfil the multiple-choice interaction type:

      if (interactiontype == 'choice' && nodes.length == 1) {
      alert('not enough choices: ' + element);
      }

      To replicate, try the attached package on the Moodle demo site or a local instance and proceed to the final page from the combo-box at the bottom. Click the 'Submit' button on the right, agree to Hand-in and await the errors.

      The faulting code resides within /mod/scorm/datamodels/scorm_13.js.php (around line 582)

      Attachments

        Issue Links

          Activity

            People

              danmarsden Dan Marsden
              pinkduck Peter Chamberlin
              Nobody Nobody
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                21/Feb/11