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

sort order Enrolled users list changes after adding or removing user

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      Confirm sorting still works correctly

      1. Visit a course with some users enrolled
      2. Visit Course Administration > Users > Enrolled users
      3. Sort by a field
      4. Confirm field is sorted ascending
      5. Sort by same field
      6. Confirm field is now sorted descending

      Confirm enrolling/removing users preserves sort

      1. Sort by a field
      2. Press Unenrol for a user
      3. Confirm table sort column/direction preserved
      4. Pres Enrol users and enrol a new user to the course
      5. Confirm table sort column/direction preserved

      Run unit tests

      1. Run vendor/bin/phpunit core_tablelib_testcase
      2. Confirm testcase passes
      Show
      Confirm sorting still works correctly Visit a course with some users enrolled Visit Course Administration > Users > Enrolled users Sort by a field Confirm field is sorted ascending Sort by same field Confirm field is now sorted descending Confirm enrolling/removing users preserves sort Sort by a field Press Unenrol for a user Confirm table sort column/direction preserved Pres Enrol users and enrol a new user to the course Confirm table sort column/direction preserved Run unit tests Run vendor/bin/phpunit core_tablelib_testcase Confirm testcase passes
    • Affected Branches:
      MOODLE_35_STABLE, MOODLE_36_STABLE, MOODLE_37_STABLE
    • Fixed Branches:
      MOODLE_36_STABLE, MOODLE_37_STABLE
    • Pull Master Branch:

      Description

      1) Go to the Users > Enrolled users screen

      2) Sort the list on Last access to course and note which user is at the top of the list, the one that was in the course most recently (you, most likely) or one that visited the course very long ago or never

      3) Remove a user from the list by clicking on the X at the end of the line and click on Unenroll when asked for a confirmation

      4) The list will now be sorted the other way around: if the most recent user was on top before, he or she will now be at the bottom of the list, or vice versa

      5) Remove another user from the list: the list will flip again and go back to its original sort order. Every time a user is removed, the sort order changes from Up to Down or back.

      6) This also happens when sorting on Surname, ID number or Email address, and when adding new users with the Enrol users button, so it looks like the current sort order flips whenever a change is made to the list (adding or removing users). Changing roles for a user in the list (with the pencil) does not change the sort order.

        Attachments

        1. MDL-64784.jpg
          50 kB
          Anna Carissa Sadia

          Issue Links

            Activity

              People

              • Votes:
                1 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  8/Jul/19

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 2 hours, 55 minutes
                  2h 55m