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

Workshop WS get_assessment_form_definition is not returning enough data for Accumulative grading

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • 3.4
    • 3.3.2
    • Workshop
    • MOODLE_33_STABLE
    • MOODLE_34_STABLE
    • MDL-60378-master
    • Hide
      1. Create a course with a workshop
      2. Configure the workshop to use "Accumulative grading" as Grading strategy (in the module settings)
      3. Enrol a couple users as student (student2 and student1) and one user as teacher
      4. In the module main page, in the Setup phase of the table describing all the phases click on "Edit assessment form"
      5. Configure a couple of Aspects to use an existing scale (via the "Best possible grade / Scale to use " setting), and leave a couple of aspects more using Points
      6. As teacher, move the workshop to the submission phase
      7. As the two students, do a submission (total of 2 submissions, one per sstudent).
      8. As teacher, move the workshop to the assessment phase, allocating the assessment of the submissions: student2 will assess student1 and vice versa.
      9. Enable "Mobile services": Site administration ► Mobile app ► Mobile settings
      10. Create a Token in the mobile app service for one of the students and the teacher:
        • Click on Site administration ► Plugins ► Web services ► Manage tokens
      11. Next, you can do a CURL REST call simulating a WS client with the student.
        • You need to replace the wstoken with the student1 one, assessmentid with the id of the assessment assigned to this user during the allocation (the id from table workshop_assessments where the reviewerid is the student1 id)

          curl 'http://localhost/m/stable_master/webservice/rest/server.php?moodlewsrestformat=json' --data 'assessmentid=3&wsfunction=mod_workshop_get_assessment_form_definition&wstoken=12a2a65aeea2a177055e233f9e303218&moodlewssettingfilter=true' | python -m "json.tool"

      12. Now check that you receive in the "dimensionsinfo" field information about the aspects you created when editing the assessment form:
        • You should see id, min, max and weight in all the aspects received and also the scale (comma separated) in those aspects using scales
      Show
      Create a course with a workshop Configure the workshop to use "Accumulative grading" as Grading strategy (in the module settings) Enrol a couple users as student (student2 and student1) and one user as teacher In the module main page, in the Setup phase of the table describing all the phases click on "Edit assessment form" Configure a couple of Aspects to use an existing scale (via the "Best possible grade / Scale to use " setting), and leave a couple of aspects more using Points As teacher, move the workshop to the submission phase As the two students, do a submission (total of 2 submissions, one per sstudent). As teacher, move the workshop to the assessment phase, allocating the assessment of the submissions: student2 will assess student1 and vice versa. Enable "Mobile services": Site administration ► Mobile app ► Mobile settings Create a Token in the mobile app service for one of the students and the teacher: Click on Site administration ► Plugins ► Web services ► Manage tokens Next, you can do a CURL REST call simulating a WS client with the student. You need to replace the wstoken with the student1 one, assessmentid with the id of the assessment assigned to this user during the allocation (the id from table workshop_assessments where the reviewerid is the student1 id) curl 'http://localhost/m/stable_master/webservice/rest/server.php?moodlewsrestformat=json' --data 'assessmentid=3&wsfunction=mod_workshop_get_assessment_form_definition&wstoken=12a2a65aeea2a177055e233f9e303218&moodlewssettingfilter=true' | python -m "json.tool" Now check that you receive in the "dimensionsinfo" field information about the aspects you created when editing the assessment form: You should see id, min, max and weight in all the aspects received and also the scale (comma separated) in those aspects using scales

      When developing the app client pferre22 has noticed that we are not retrieving the scale used (we get the id, but we need the scale elements).

      We should:

      • Extend the WS to allow plugins to return additional data via a callback (get_config_for_external()) like we did for database or assignment
      • Or create a new generic WS to return scales information based on id "core_grades_get_scale" (the problem here is that there is no way to validate if the user can see the scale or not because they are no-context/permission based).

            jleyva Juan Leyva
            jleyva Juan Leyva
            David Mudrák (@mudrd8mz) David Mudrák (@mudrd8mz)
            David Monllaó David Monllaó
            Adrian Greeve Adrian Greeve
            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.