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

"Re-sort courses by name" in natural order

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • 2.2.6, 2.3.3
    • 2.2.5, 2.3.2, 2.4
    • Course
    • MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE
    • MOODLE_22_STABLE, MOODLE_23_STABLE
    • MDL-34765-master
    • Hide

      Test pre-requisites

      1. Create a few courses named as followed (keep the order and case):
      • Course 10
      • course 2
      • course 11
      • Course 0
      • Course 1

      Test steps

      1. Navigate to Home ► Courses ► Courses ► Add/edit courses
      2. Browse the category you've created the course in
      3. Click on the button 'Re-sort courses by name'
      4. Make sure the order makes sense (from a human point of view)
      Show
      Test pre-requisites Create a few courses named as followed (keep the order and case): Course 10 course 2 course 11 Course 0 Course 1 Test steps Navigate to Home ► Courses ► Courses ► Add/edit courses Browse the category you've created the course in Click on the button 'Re-sort courses by name' Make sure the order makes sense (from a human point of view)

      Moodle uses a very basic sortorder, provided by the DBMS. If you have e.g. the following courses:
      "Course 1", "Course 2", "Course 10", "Course 3" and press "Re-sort courses by name" on /course/category.php, you will get the courses in the following ("unnatural") order:

      "Course 1"
      "Course 10"
      "Course 2"
      "Course 3"

      Sorting should be done in PHP to improve the user experience.

      Replication steps:

      1. Create courses with numeric numbering similar to the list above
      2. Ensure that your site has more than one catagory
      3. Navigate to one of the courses
      4. In the breadcrumbs, click on the category name

      Expected result: Course names should be sorted in natural order

      Actual result: Course names are sorted in Unicode order.

            fred Frédéric Massart
            marxist Tobias Marx
            Rajesh Taneja Rajesh Taneja
            Sam Hemelryk Sam Hemelryk
            Rossiani Wijaya Rossiani Wijaya
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

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