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

Students unable to open published submissions

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.3.4, 2.4.1, 2.5
    • Fix Version/s: 2.3.5, 2.4.2
    • Component/s: Workshop
    • Labels:
    • Testing Instructions:
      Hide

      Testing difficulty: easy

      1. Prepare a workshop activity with at least two students (let us call them Arnold and Sylvester) participating. Make sure to set "Submission settings > Maximum number of submission attachments" to a number higher than 0.
      2. During the Submission phase, log in as Arnold and submit a work containing files both embedded into the submission text and attached to the submission.
      3. Log in as Sylvester and again, submit your work containing files in both areas.
      4. Close the workshop activity and publish Arnold's submission.
      5. TEST: Make sure that Sylvester is able to see Arnold's submission including all images.
      6. TEST: Make sure Arnold is not able to see Sylvester's submission nor files in it (using direct URL).
      Show
      Testing difficulty: easy Prepare a workshop activity with at least two students (let us call them Arnold and Sylvester) participating. Make sure to set "Submission settings > Maximum number of submission attachments" to a number higher than 0. During the Submission phase, log in as Arnold and submit a work containing files both embedded into the submission text and attached to the submission. Log in as Sylvester and again, submit your work containing files in both areas. Close the workshop activity and publish Arnold's submission. TEST: Make sure that Sylvester is able to see Arnold's submission including all images. TEST: Make sure Arnold is not able to see Sylvester's submission nor files in it (using direct URL).
    • Affected Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE, MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-37522-published-attachment

      Description

      Published submissions throw an error if student is not submitter or reviewer.

      Steps to reproduce:

      • Enable "Publish submission" for a submission in workshop
      • With a participant (student role) who is neither the submitter nor reviewer try to open the submission.
      • The user gets a "Sorry, the requested file could not be found" error

      As far as I understand the user should be allowed to open the submission if the submission is published and the user has the capability mod/workshop:viewpublishedsubmissions. However, there is no such condition in mod/workshop/lib.php.

      The error is thrown in mod/workshop/lib.php, line 1254 (Version 2.3.4 (Build: 20130114))
      http://git.moodle.org/gw?p=moodle.git;a=blob;f=mod/workshop/lib.php;h=cf37a23521b7c60fd48e70665e6af16a0fd7269d;hb=refs/heads/MOODLE_23_STABLE#l1254

      This issue is related to MDL-32638.

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/Mar/13