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

CLONE -Assign Roles page - existing users is only sorted by last name, while potential users is sorted by last name then first name

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.8.1, 1.9.5, 1.9.10
    • 1.9.11
    • Administration
    • None
    • MOODLE_18_STABLE, MOODLE_19_STABLE
    • MOODLE_19_STABLE

    Description

      When assigning roles, the potential uses column is sorted first by last name then by first name, while the existing users only sorts by last name.

      This is easily fixed by adding the sort option to the get_role_users like so:

      if (!$contextusers = get_role_users($roleid, $context, false, 'u.id, u.firstname, u.lastname, u.email, r.hidden','lastname ASC, firstname ASC'))

      { $contextusers = array(); }

      Attachments

        1. MDL-20607.patch
          0.8 kB
        2. mdl-20607-after.png
          mdl-20607-after.png
          152 kB
        3. mdl-20607-before.png
          mdl-20607-before.png
          152 kB

        Issue Links

          Activity

            People

              aborrow Anthony Borrow
              monkey mh
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                21/Feb/11