Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 2.5
    • Component/s: Forms Library, Gradebook
    • Labels:
    • Testing Instructions:
      Hide

      You'll need two gradeable activities. One using a numeric grade. The other using a custom scale.

      As a teacher or admin go to the grader report and turn editing on. Click the edit/cog icon next to an individual student grade. Tick 'overridden' if it isnt ticked already. Edit the student's grade and click update.

      Repeat this for both activities. Make sure you don't see the warning in this MDL's description and that the grade changes are saved correctly.

      Show
      You'll need two gradeable activities. One using a numeric grade. The other using a custom scale. As a teacher or admin go to the grader report and turn editing on. Click the edit/cog icon next to an individual student grade. Tick 'overridden' if it isnt ticked already. Edit the student's grade and click update. Repeat this for both activities. Make sure you don't see the warning in this MDL's description and that the grade changes are saved correctly.
    • Affected Branches:
      MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_25_STABLE
    • Pull Master Branch:
      MDL-38833_settype

      Description

      If I go to the grader report, turn editing on, click the edit icon for an individual student grade then save the resulting form the following is displayed.

      Did you remember to call setType() for 'finalgrade'? Defaulting to PARAM_RAW cleaning.
       
          line 1275 of /lib/formslib.php: call to debugging()
          line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
          line 202 of /lib/formslib.php: call to moodleform->_process_submission()
          line 105 of /grade/edit/tree/grade.php: call to moodleform->moodleform()
      

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              Hide
              andyjdavis Andrew Davis added a comment -

              Adding a simple fix and testing instructions. Putting this up for peer review.

              Show
              andyjdavis Andrew Davis added a comment - Adding a simple fix and testing instructions. Putting this up for peer review.
              Hide
              andyjdavis Andrew Davis added a comment - - edited

              Note that the reason I went for PARAM_RAW instead of PARAM_ALPHANUMEXT is that PARAM_ALPHANUMEXT removes full stops meaning that 1.25 becomes 125.

              It may be possible to use PARAM_FLOAT but some countries use a comma for a decimal separator meaning that additional processing is required making that a more complex option.

              Show
              andyjdavis Andrew Davis added a comment - - edited Note that the reason I went for PARAM_RAW instead of PARAM_ALPHANUMEXT is that PARAM_ALPHANUMEXT removes full stops meaning that 1.25 becomes 125. It may be possible to use PARAM_FLOAT but some countries use a comma for a decimal separator meaning that additional processing is required making that a more complex option.
              Hide
              ankit_frenz Ankit Agarwal added a comment -

              Hi Andrew,
              The Patch looks okay and you can go ahead with integration. However I think PARAM_FLOAT should be updated or atleast a new param should be created to handle issues like this. It doesnt make much sense to have a PARAM_FLOAT, which we cannot use when we are expecting float entries.

              Thanks

              Show
              ankit_frenz Ankit Agarwal added a comment - Hi Andrew, The Patch looks okay and you can go ahead with integration. However I think PARAM_FLOAT should be updated or atleast a new param should be created to handle issues like this. It doesnt make much sense to have a PARAM_FLOAT, which we cannot use when we are expecting float entries. Thanks
              Hide
              ankit_frenz Ankit Agarwal added a comment -

              Sorry forgot to click button

              Show
              ankit_frenz Ankit Agarwal added a comment - Sorry forgot to click button
              Hide
              andyjdavis Andrew Davis added a comment -

              I've raised MDL-39360 to look further into the param_raw Vs param_float issue once the 2.5 rush is past.

              Rebased. Submitting for integration.

              Show
              andyjdavis Andrew Davis added a comment - I've raised MDL-39360 to look further into the param_raw Vs param_float issue once the 2.5 rush is past. Rebased. Submitting for integration.
              Hide
              damyon Damyon Wiese added a comment -

              Thanks Andrew,

              This is the correct approach for floats for now. Integrated to master.

              Show
              damyon Damyon Wiese added a comment - Thanks Andrew, This is the correct approach for floats for now. Integrated to master.
              Hide
              damyon Damyon Wiese added a comment -

              (Testing this to keep the dashboard clean).

              Show
              damyon Damyon Wiese added a comment - (Testing this to keep the dashboard clean).
              Hide
              damyon Damyon Wiese added a comment -

              Works as described.

              Thanks Andrew.

              Show
              damyon Damyon Wiese added a comment - Works as described. Thanks Andrew.
              Hide
              poltawski Dan Poltawski added a comment -

              Thanks! You're changes are now spread to the world through this git and our source control repositories.

              No time to rest though, we've got days to make 2.5 the best yet!

              ciao

              Show
              poltawski Dan Poltawski added a comment - Thanks! You're changes are now spread to the world through this git and our source control repositories. No time to rest though, we've got days to make 2.5 the best yet! ciao

                People

                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    14/May/13