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

Forum rating display broken when rating value is 0 (not fixed - see MDL-54620)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.5, 2.3.2, 2.9, 3.1
    • Fix Version/s: 2.9.6, 3.0.4
    • Component/s: Forum, Ratings
    • Labels:
    • Testing Instructions:
      Hide
      1. create a forum and a post from a student user
      2. Allow ratings on the forum and use an aggregation method such as 'minimum'
      3. As a teacher, rate the student's post, assigning it a score of zero.
      4. Refresh the page.
        • Confirm that display is 'Minimum rating: 0 (1)'
      Show
      create a forum and a post from a student user Allow ratings on the forum and use an aggregation method such as 'minimum' As a teacher, rate the student's post, assigning it a score of zero. Refresh the page. Confirm that display is 'Minimum rating: 0 (1)'
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_29_STABLE, MOODLE_31_STABLE
    • Fixed Branches:
      MOODLE_29_STABLE, MOODLE_30_STABLE
    • Pull Master Branch:
      MDL-36234-master

      Description

      When a student's post is rated with a value of 0, the student sees the grade display under their post as:
      Maximum rating: (1)

      When that same post is rated with a non-zero value, say 4, the student sees the grade display under their post as:
      Maximum rating: 4 (1)

      That is, when the value is 0, the rating display seems to use a space instead of the actual number.

      This currently exists in Moodle 2.3.2 and can be easily reproduced on demo.moodle.org as follows, in the CF101 demo course:

      1) Log in as teacher to the CF101 demo course
      2) Create a forum with default settings except for:
      2a) Change "Aggregate type" to "Maximum rating"
      2b) Change Scale dropdown to "5"
      3) Log in as student and add a post to the forum
      4) Log in as teacher and rate the student's forum post with a 0
      5) Log in as student and see the rating.

      Under the post, the rating text display should say:
      Maximum rating: 0 (1)

      Instead, as of 10/26/12 on Moodle 2.3.2, it says:
      Maximum rating: (1)

      See attached screenshot for the bug.

        Attachments

        1. Picture 12.png
          Picture 12.png
          97 kB
        2. Rating01.png
          Rating01.png
          46 kB
        3. Rating02.png
          Rating02.png
          14 kB
        4. StudentViewRating.png
          StudentViewRating.png
          11 kB

          Issue Links

            Activity

              People

              Assignee:
              kwiliarty Kevin Wiliarty
              Reporter:
              instructoit UMass Amherst Instructional Media Lab
              Peer reviewer:
              Jun Pataleta
              Integrator:
              David Monllaó
              Tester:
              Mark Nelson
              Participants:
              Component watchers:
              Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                9/May/16