Moodle
  1. Moodle
  2. MDL-28283

Course Completion will not allow completion dates to be set outside of the range 2000 - 2010

    Details

    • Database:
      Any
    • Testing Instructions:
      1. Follow steps 1-5 as specified in the description.
      2. Now you should see years in the range 1970-2020 in the drop down
    • Workaround:
      Hide

      I've created a patch to work around this issue. This patch was created against Moodle Head however the code it affects did not change between Moodle 2.0.3 and 2.1. I've only been able to perform limited testing of the patch, but for my installation (Moodle 2.0.3+, no contrib modules) it works.

      Show
      I've created a patch to work around this issue. This patch was created against Moodle Head however the code it affects did not change between Moodle 2.0.3 and 2.1. I've only been able to perform limited testing of the patch, but for my installation (Moodle 2.0.3+, no contrib modules) it works.
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_20_STABLE, MOODLE_21_STABLE
    • Fixed Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE
    • Pull Master Branch:
      MDL-28283-master
    • Rank:
      17914

      Description

      Not sure if this is a bug or intended behaviour, if it's not a bug please refile this in the correct spot.

      I am using completion tracking on my Moodle site. For one of the courses I need to mark all students as complete once a certain date in 2012 has passed. However, the Date section of the Completion Tracking page only allows me to select dates between 2000 and 2010.

      Here are the steps to reproduce the problem:

      1. Enable completion tracking for the site (under Site Administration -> Course Default Settings)
      2. Create a new course and enable completion tracking for that course (under Course Administration -> Edit Settings)

      • Creating a new course isn't mandatory, however the issue may be easier to test using a course with no students
        3. Go to Course Administration -> Completion Tracking
        4. Scroll down to the section labelled 'Date'
        5. Click on the dropdown box labelled 'Year'

      What was observed:

      • A dropdown box appeared with a range of years spanning 2000 - 2010.

      What was expected:

      • A dropdown box containing a range of years spanning from a fixed year in the past (ie 1970) to a fixed year in the future (ie 2020).
        or
      • A dropdown box containing a range of years relative to the current year (ie current year +/- 5 years).

      This issue affects all versions of Moodle 2.0 and 2.1.

        Activity

        Hide
        Michael de Raadt added a comment -

        Thanks for reporting this and providing a solution.

        We need a policy on a relative range of years. I'm not sure if we have this.

        Show
        Michael de Raadt added a comment - Thanks for reporting this and providing a solution. We need a policy on a relative range of years. I'm not sure if we have this.
        Hide
        Ankit Agarwal added a comment -

        Should cleanly chery-pick to stables. Will upload other branches after the review.
        Thanks

        Show
        Ankit Agarwal added a comment - Should cleanly chery-pick to stables. Will upload other branches after the review. Thanks
        Hide
        Ankit Agarwal added a comment -

        sorry for the spam.
        Fixed the typo in githuburl

        Show
        Ankit Agarwal added a comment - sorry for the spam. Fixed the typo in githuburl
        Hide
        Rajesh Taneja added a comment -

        Patch looks Great, Anita and Ankit.

        Please update test instructions, before pushing it for integration review

        Show
        Rajesh Taneja added a comment - Patch looks Great, Anita and Ankit. Please update test instructions, before pushing it for integration review
        Hide
        Ankit Agarwal added a comment -

        Thanks Raj for the review.
        Up for integration!

        Show
        Ankit Agarwal added a comment - Thanks Raj for the review. Up for integration!
        Hide
        Sam Hemelryk added a comment -

        Thanks Ankit this has been integrated now

        Show
        Sam Hemelryk added a comment - Thanks Ankit this has been integrated now
        Hide
        Andrew Davis added a comment -

        Works as described. Passing.

        Show
        Andrew Davis added a comment - Works as described. Passing.
        Hide
        Eloy Lafuente (stronk7) added a comment -

        It is late here and I'm very tired but I didn't want to go to sleep before expressing my admiration for your amazing collaboration. Thanks!

        Closing as fixed, heading to zzzZZZzzz, niao

        Show
        Eloy Lafuente (stronk7) added a comment - It is late here and I'm very tired but I didn't want to go to sleep before expressing my admiration for your amazing collaboration. Thanks! Closing as fixed, heading to zzzZZZzzz, niao

          People

          • Votes:
            8 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: