Moodle
  1. Moodle
  2. MDL-35581 META: tasks related to RTL theme fixes before 2.4 freeze (Week 39)
  3. MDL-35202

Unable to set a new grade or update old grade when using the new Assignment type (Assign) while in Hebrew UI

    Details

    • Testing Instructions:
      Hide
      1. Change the language to hebrew (he)
      2. Go to the grading table
      3. Click the grade button for a submission
      4. Change the grade
      5. Click save on the grading form (top right in the group of buttons)
        Expected result: The grading table should show the updated grade
        Actual result: The grading table shows the old grade
      Show
      Change the language to hebrew (he) Go to the grading table Click the grade button for a submission Change the grade Click save on the grading form (top right in the group of buttons) Expected result: The grading table should show the updated grade Actual result: The grading table shows the old grade
    • Workaround:
      Hide

      See code change in the description.

      Show
      See code change in the description.
    • Affected Branches:
      MOODLE_22_STABLE, MOODLE_23_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE
    • Pull Master Branch:
    • Rank:
      43841

      Description

      When UI is set to Hebrew (and probably other non English languages) It is not possible to update a grade or set a new grade in the new "Assign" (assignment type) submission form (mod/assign/view.php?id=XX&action=grading).

      Changing the following fixes this issue:
      moodle2/mod/assign/locallib.php (line 330)

                  } else if (optional_param('savegrade', null, PARAM_ALPHA)) {
      

      change to:

                  } else if (optional_param('savegrade', null, PARAM_RAW)) {
      

        Issue Links

          Activity

          Hide
          Damyon Wiese added a comment -

          This was caused because I am using submit buttons and I am just checking to see if they have a value - but PARAM_ALPHA strips all the non-ascii chars. Change to PARAM_RAW seems safe and correct here. This change applies to all the submit buttons on the grading form.

          Show
          Damyon Wiese added a comment - This was caused because I am using submit buttons and I am just checking to see if they have a value - but PARAM_ALPHA strips all the non-ascii chars. Change to PARAM_RAW seems safe and correct here. This change applies to all the submit buttons on the grading form.
          Hide
          Dan Poltawski added a comment -

          The main moodle.git repository has just been updated with latest weekly modifications. You may wish to rebase your PULL branches to simplify history and avoid any possible merge conflicts. This would also make integrator's life easier next week.

          TIA and ciao

          Show
          Dan Poltawski added a comment - The main moodle.git repository has just been updated with latest weekly modifications. You may wish to rebase your PULL branches to simplify history and avoid any possible merge conflicts. This would also make integrator's life easier next week. TIA and ciao
          Hide
          Dan Poltawski added a comment -

          This is a good reason not to use this approach, its a bit yukky, would be good to move away from it.

          But i'll ignore that for now since the fix makes sense.

          Integrated to 23 and maser. Thanks Daymon.

          Show
          Dan Poltawski added a comment - This is a good reason not to use this approach, its a bit yukky, would be good to move away from it. But i'll ignore that for now since the fix makes sense. Integrated to 23 and maser. Thanks Daymon.
          Hide
          Mark Nelson added a comment -

          Works as expected. Passed.

          Show
          Mark Nelson added a comment - Works as expected. Passed.
          Hide
          Dan Poltawski added a comment -

          Congratulations, you've done it!

          Nf n erjneq sbe fhpprfshy vagrtengvba vagb guvf jrrxf eryrnfr, V pna abj qvfpybfr gb lbh gur rkvfgnapr bs shapgvba fge_ebg13(), gb tb va lbhe gbbyxvg nybat jvgu uggc://cuc.arg/znahny/ra/shapgvba.tmtrgff.cuc

          Cyrnfr qb abg nyybj guvf vasbezngvba gb cnff shegure.

          Show
          Dan Poltawski added a comment - Congratulations, you've done it! Nf n erjneq sbe fhpprfshy vagrtengvba vagb guvf jrrxf eryrnfr, V pna abj qvfpybfr gb lbh gur rkvfgnapr bs shapgvba fge_ebg13(), gb tb va lbhe gbbyxvg nybat jvgu uggc://cuc.arg/znahny/ra/shapgvba.tmtrgff.cuc Cyrnfr qb abg nyybj guvf vasbezngvba gb cnff shegure.

            People

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

              Dates

              • Created:
                Updated:
                Resolved: