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

When searching for users, list any exact matches first

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major Major
    • 2.4
    • 2.2.4
    • Libraries
    • MOODLE_22_STABLE
    • MOODLE_24_STABLE
    • Hide

      Please test this, in particular, on Oracle and MS SQL server.

      1. On Users > Permissions > User policies, add idnumber to the selected Show user identity fields.

      2. Create a user with idnumber s, and full name Students ZZZ. Then create a lot of other accounts with idnumbers s1, ... s100, with last names that come in alphabetical order before ZZZ.

      (Actually, 100 users here is excessive. A few is enough to see the effect of the change.)

      3. Now, try to enrol the user with idnumber s, by searching for 's' in the manual enrolment pop-up.

      4. Verify that Students ZZZ is listed first in the list of matching users.

      You need to do similar checks in other places where users are searched for or just displayed sorted (obviously fewer checks to do when there is no search):

      5. Both user selectors on the assign roles page at system level.

      6. Both user selectors on the assign other users page at course level.

      7. Both user selectors on the assign roles page at activity level.

      8. Both user selectors on the assign admins screen.

      9. In the web service admin UI, on the form where you create a token for a user.

      10. Both user selectors on the manage cohort members screen.

      11. Both user selectors on the non-javascript manage enrolments page (enrol/manual/manage.php, go to Manage enrolments, then click on the two face icon for the manual enrolment plugin.)

      12. Check the list of teachers is still correctly displayed beside each course in the course list.

      13. Check that mnet enrolment still works. (Sorry, I am not sure of how this is supposed to work.)

      14. For self-enrolment, check that the from address of the welcome email is one of the teachers in the course.

      15. In gradebook import:
      15a. Create an import file with the idnumbers of some users who do exist, but who are not enrolled in the course.
      15b. Try to import this file. At some point in the process, you should see a list of users who are not enrolled. Make sure that is displayed correctly, and that the users are in the right order.

      16. On the front page of the groups UI, the list of users where you select one group.

      17. Lists of users on the groups overview page.

      18. Both user selectors on the page where you add/remove users from a group.

      19. Find at least one admin setting using admin_setting_users_with_capability, e.g. the list of users to notify about course requests on Site administration, Courses, Course request. Test that.

      20. I don't know what mnet/service/enrol/course.php does, but I changed it, so it should be tested. In fact, there are several user selectors in the mnet UI. Wherever they are, they need to be tested.

      21. Sort order where users are listed in the choice module.

      22. Forum show and manage subscribers page. That is, turn editing on when looking at the list of subscribers. Also check a forum with forced subscription on.

      23. Lesson module essay qtype UI. (Sorry, this is another area I don't know much about.)

      24. Sorting of lesson reports.

      25. Quiz module, when viewing user overrides, check the sort order. When editing them the list of users in the form select menu.

      26. Lots of places users are listed in the workshop module.

      27. Logs report.

      28. Security report.

      29. Stats report.

      Show
      Please test this, in particular, on Oracle and MS SQL server. 1. On Users > Permissions > User policies, add idnumber to the selected Show user identity fields. 2. Create a user with idnumber s, and full name Students ZZZ. Then create a lot of other accounts with idnumbers s1, ... s100, with last names that come in alphabetical order before ZZZ. (Actually, 100 users here is excessive. A few is enough to see the effect of the change.) 3. Now, try to enrol the user with idnumber s, by searching for 's' in the manual enrolment pop-up. 4. Verify that Students ZZZ is listed first in the list of matching users. You need to do similar checks in other places where users are searched for or just displayed sorted (obviously fewer checks to do when there is no search): 5. Both user selectors on the assign roles page at system level. 6. Both user selectors on the assign other users page at course level. 7. Both user selectors on the assign roles page at activity level. 8. Both user selectors on the assign admins screen. 9. In the web service admin UI, on the form where you create a token for a user. 10. Both user selectors on the manage cohort members screen. 11. Both user selectors on the non-javascript manage enrolments page (enrol/manual/manage.php, go to Manage enrolments, then click on the two face icon for the manual enrolment plugin.) 12. Check the list of teachers is still correctly displayed beside each course in the course list. 13. Check that mnet enrolment still works. (Sorry, I am not sure of how this is supposed to work.) 14. For self-enrolment, check that the from address of the welcome email is one of the teachers in the course. 15. In gradebook import: 15a. Create an import file with the idnumbers of some users who do exist, but who are not enrolled in the course. 15b. Try to import this file. At some point in the process, you should see a list of users who are not enrolled. Make sure that is displayed correctly, and that the users are in the right order. 16. On the front page of the groups UI, the list of users where you select one group. 17. Lists of users on the groups overview page. 18. Both user selectors on the page where you add/remove users from a group. 19. Find at least one admin setting using admin_setting_users_with_capability, e.g. the list of users to notify about course requests on Site administration, Courses, Course request. Test that. 20. I don't know what mnet/service/enrol/course.php does, but I changed it, so it should be tested. In fact, there are several user selectors in the mnet UI. Wherever they are, they need to be tested. 21. Sort order where users are listed in the choice module. 22. Forum show and manage subscribers page. That is, turn editing on when looking at the list of subscribers. Also check a forum with forced subscription on. 23. Lesson module essay qtype UI. (Sorry, this is another area I don't know much about.) 24. Sorting of lesson reports. 25. Quiz module, when viewing user overrides, check the sort order. When editing them the list of users in the form select menu. 26. Lots of places users are listed in the workshop module. 27. Logs report. 28. Security report. 29. Stats report.

      1. On Users > Permissions > User policies, add idnumber to the selected Show user identity fields.

      2. Create a user with idnumber s, and full name Students ZZZ. Then create a lot of other accounts with idnumbers s1, ... s100, with last names that come in alphabetical order before ZZZ.

      3. Now, try to enrol the user with idnumber s, by searching for 's' in the manual enrolment pop-up.

      Current behaviour: Students ZZZ is somewhere off the bottom of the list.

      Desired behaviour: List exact matches first.

        1. danp-enrolment-screen.png
          211 kB
          Dan Poltawski
        2. danp-role-screen.png
          255 kB
          Dan Poltawski
        3. danp-weirdsort-forum.png
          22 kB
          Dan Poltawski
        4. danp-weirdsort-group.png
          18 kB
          Dan Poltawski
        5. mdl34657.png
          44 kB
          Frédéric Massart

            timhunt Tim Hunt
            timhunt Tim Hunt
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Frédéric Massart Frédéric Massart
            Votes:
            20 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.