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

Assignment: Advanced upload type - error in setting default values when creating new assignment

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 1.9.2
    • Fix Version/s: 1.9.3, 2.0
    • Component/s: Assignment (2.2)
    • Labels:
      None
    • Environment:
      any
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE, MOODLE_20_STABLE

      Description

      assignment type (advanced) upload, in file assignment.class.php, in function setup_elements() the default value for 'trackdrafts' is not set correctly.

      Near line 1053:
      $mform->addElement('select', 'var4', get_string("trackdrafts", "assignment"), $ynoptions);
      $mform->setHelpButton('var4', array('trackdrafts', get_string('trackdrafts', 'assignment'), 'assignment'));
      $mform->setDefault('trackdrafts', 1);

      The last line should be
      $mform->setDefault('var4', 1);

      The form's variable name is var4 - not trackdrafts.

        Gliffy Diagrams

          Activity

          Hide
          poltawski Dan Poltawski added a comment -

          Thanks Brian, i've fixed this in CVS

          Show
          poltawski Dan Poltawski added a comment - Thanks Brian, i've fixed this in CVS
          Hide
          jerome Jérôme Mouneyrac added a comment -

          checked and tested on 1.9. 'Enable Send for marking' sets to yes be default. It has been fixed.

          Show
          jerome Jérôme Mouneyrac added a comment - checked and tested on 1.9. 'Enable Send for marking' sets to yes be default. It has been fixed.
          Hide
          jerome Jérôme Mouneyrac added a comment -

          Thank you for the report and the fix.

          Show
          jerome Jérôme Mouneyrac added a comment - Thank you for the report and the fix.

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                15/Oct/08