Moodle
  1. Moodle
  2. MDL-30218

Activities filter for recent submissions shows submissions when it should not

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Not a bug
    • Affects Version/s: 2.1.2
    • Fix Version/s: None
    • Component/s: Course
    • Labels:
    • Testing Instructions:
      Hide

      Navigate to /admin/settings.php?section=modsettingassignment
      Set assignment_showrecentsubmissions to false
      Navigate to /course/recent.php?id=<n>
      Click Advanced
      Activities dropdown no longer includes all assignments

      Show
      Navigate to /admin/settings.php?section=modsettingassignment Set assignment_showrecentsubmissions to false Navigate to /course/recent.php?id=<n> Click Advanced Activities dropdown no longer includes all assignments
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_21_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      wip-MDL-30218-master
    • Rank:
      26479

      Description

      When $CFG->assignment_showrecentsubmissions is set to false, students still see assignment filter options in the Activities filter for Recent submissions. This is confusing.

      Steps to reproduce:

      1. Navigate to /admin/settings.php?section=modsettingassignment
      2. Set assignment_showrecentsubmissions to false
      3. Navigate to /course/recent.php?id=<n>
      4. Click Advanced
      5. Activities dropdown includes all assignments

      Patch attached for removing assignments from this list where $CFG->assignment_showrecentsubmissions is false and user does not have capability moodle/grade:viewall

        Issue Links

          Activity

          Hide
          Michael de Raadt added a comment -

          Thanks for reporting that and providing a solution.

          Show
          Michael de Raadt added a comment - Thanks for reporting that and providing a solution.
          Hide
          Jason Fowler added a comment -

          Up for peer review, I have implemented the patch for master, and will cherry-pick and back port after the peer review

          Show
          Jason Fowler added a comment - Up for peer review, I have implemented the patch for master, and will cherry-pick and back port after the peer review
          Hide
          Michael de Raadt added a comment -

          Carrying over to the new sprint.

          Show
          Michael de Raadt added a comment - Carrying over to the new sprint.
          Hide
          Jason Fowler added a comment -

          Requesting peer review for this one now

          Show
          Jason Fowler added a comment - Requesting peer review for this one now
          Hide
          Adrian Greeve added a comment -

          The patch looks good, Thank Jason for putting up with my barrage of questions. Please submit for integration review.

          Show
          Adrian Greeve added a comment - The patch looks good, Thank Jason for putting up with my barrage of questions. Please submit for integration review.
          Hide
          Sam Hemelryk added a comment -

          Hi guys,

          I've just been looking at this now.
          To be truthful I don't really like this solution because of the hardcoding that is going on in recent_form.php. Especially given the assignment module is about to be replaced in 2.3 by the new assignment module.
          Also just noting that while this patch removes assignments from the drop down navigation it doesn't remove them from the actual page content which is pretty confusing as well.

          I'm sending it back this week sorry so that it can be further looked at.

          Cheers
          Sam

          Show
          Sam Hemelryk added a comment - Hi guys, I've just been looking at this now. To be truthful I don't really like this solution because of the hardcoding that is going on in recent_form.php. Especially given the assignment module is about to be replaced in 2.3 by the new assignment module. Also just noting that while this patch removes assignments from the drop down navigation it doesn't remove them from the actual page content which is pretty confusing as well. I'm sending it back this week sorry so that it can be further looked at. Cheers Sam
          Hide
          Sam Hemelryk added a comment -

          (sorry wrong button)

          Show
          Sam Hemelryk added a comment - (sorry wrong button)
          Hide
          Jason Fowler added a comment -

          the assignments are already removed from the actual page content - for all that need them removed. Honestly, I didn't understand the need for it, but spoke to MdR and he seemed to think it worth while.

          Show
          Jason Fowler added a comment - the assignments are already removed from the actual page content - for all that need them removed. Honestly, I didn't understand the need for it, but spoke to MdR and he seemed to think it worth while.
          Hide
          Adrian Greeve added a comment -

          Jason and I had an extensive talk about the need for this patch. I personally don't think that it's necessary, but I can understand what Amanda (reporter) deems to be a problem. I see no problem with just closing this issue and moving on.

          Show
          Adrian Greeve added a comment - Jason and I had an extensive talk about the need for this patch. I personally don't think that it's necessary, but I can understand what Amanda (reporter) deems to be a problem. I see no problem with just closing this issue and moving on.
          Hide
          Rajesh Taneja added a comment -

          I agree with Sam, that this patch should be again looked at, for:

          1. removing Hard-coding
          2. Assignments should not be visible on page and in drop-down and in block

          IMO Show recent submission is a break in functionality and should be fixed. If required, should be tested for new assignment module as well (Probably a subtask for new assignment module)

          Show
          Rajesh Taneja added a comment - I agree with Sam, that this patch should be again looked at, for: removing Hard-coding Assignments should not be visible on page and in drop-down and in block IMO Show recent submission is a break in functionality and should be fixed. If required, should be tested for new assignment module as well (Probably a subtask for new assignment module)
          Hide
          Jason Fowler added a comment -

          the drop down is irrelevant as no content is actually shown, and as long as you don't have the ability to grade the assignments, the submissions won't be shown already. The only purpose of this issue was to remove the entry for the drop down from the list. That is all.

          +1 to close

          Show
          Jason Fowler added a comment - the drop down is irrelevant as no content is actually shown, and as long as you don't have the ability to grade the assignments, the submissions won't be shown already. The only purpose of this issue was to remove the entry for the drop down from the list. That is all. +1 to close
          Hide
          Jason Fowler added a comment -

          CLosing this as displaying the dropdown in the filter isn't really a problem, as long as the assignment submissions aren't being displayed - and they aren't.

          Show
          Jason Fowler added a comment - CLosing this as displaying the dropdown in the filter isn't really a problem, as long as the assignment submissions aren't being displayed - and they aren't.

            People

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

              Dates

              • Created:
                Updated:
                Resolved: