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

LTI: honor the lineitem definition in Content Item selection

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      Prerequisite
      1. Site is configured with at least one course
      2. LTI Test tool is installed as a site external tool:
        1. Log in as an administrator
        2. Navigate to Site Administration > Plugins > External tool > Manage tools
        3. Click on configure a tool manually
        4. Fill the form as follow:
          1. Tool name: LTI Test Tool
          2. Tool url: https://lti.tools/test/tp.php
        5. Consumer key: any value would do
        6. Shared secret: secret
        7. Click on ‘Show more’
        8. Check Content-Item message
        9. Change the 'Privacy' setting ‘Accept grades from the tool’ to 'Always'.
        10. Save changes.
      Test 1 - Always create a gradebook column

      In this test we verify that when an app is configured to always create a gradebook column for each link a gradebook column will always be created, regardless whether the content item contains a gradebook column definition or not.

      1. As instructor, log to a course
      2. Turn editing ON
      3. Click Add an activity or resource and select external tool
      4. On the Add external tool page, select LTI Test tool for preconfigured tool
      5. Click on Select Content
      6. In the modal:
        1. Click content-item button
        2. Select LTI Launch (without gradebook column definition)
        3. At the bottom of the page, click return selection
      7. When the modal is closed, verify:
        1. Grade section is visible
        2. Expand the grade section
        3. Maximum Score: 100
        4. Expand Common module settings
        5. Click on ‘Show more’
        6. Verify id-number is empty
      8. Click on Select Content
      9. In the modal:
        1. Click content-item button
        2. Select LTI Launch 2 (it contains a gradebook definition)
        3. At the bottom of the page, click return selection
      10. When the modal is closed, verify:
        1. Grade section is visible
        2. Expand the grade section
        3. Maximum Score: 50
        4. Expand Common module settings
        5. Click show advanced
        6. Verify id-number has a value starting with a-
      Test 2 - Delegate to Teacher

      In this test we verify that when an app is configured to set or not a gradebook column on a per link bases, a gradebook column will always be enabled and populated only if the content item contains a gradebook column.

      1. Log in as the admin.
      2. Edit the tool created at the start of the testing instructions (in the Prerequisites).
      3. Change the 'Privacy' setting ‘Accept grades from the tool’ to 'Delegate to teacher'.
      4. Save changes.
      5. As instructor, log to a course
      6. Turn editing ON
      7. Click Add an activity or resource and select external tool
      8. On the Add external tool page, select LTI Test tool for preconfigured tool
      9. Click on Select Content
      10. In the modal:
        1. Click content-item button
        2. Select LTI Launch (without gradebook column definition)
        3. At the bottom of the page, click return selection
      11. When the modal is closed, verify:
        1. Grade section is not visible
        2. Expand Common module settings
        3. Click on ‘Show more’
        4. Verify id-number is empty
      12. Click on Select Content
      13. In the modal:
        1. Click content-item button
        2. Select LTI Launch 2 (it contains a gradebook definition)
        3. At the bottom of the page, click return selection
      14. When the modal is closed, verify:
        1. Grade section is visible
        2. Expand the grade section
        3. Maximum Score: 50
        4. Verify id-number has a value starting with a-
      Test 3 - Never create a gradebook column

      In this test we verify that when an app is configured to never allow a gradebook column, a gradebook column will not be enabled and populated even if the content item does contain a gradebook column.

      1. Log in as the admin.
      2. Edit the tool created at the start of the testing instructions (in the Prerequisites).
      3. Change the 'Privacy' setting ‘Accept grades from the tool’ to 'Never'.
      4. Save changes.
      5. As instructor, log to a course
      6. Turn editing ON
      7. Click Add an activity or resource and select external tool
      8. On the Add external tool page, select LTI Test tool for preconfigured tool
      9. Click on Select Content
      10. In the modal:
        1. Click content-item button
        2. Select LTI Launch 2 (contains a gradebook column)
        3. At the bottom of the page, click return selection
      11. When the modal is closed, verify:
        1. Grade section is not visible
        2. Expand Common module settings
        3. Click on ‘Show more’
        4. Verify id-number is empty.
      Show
      Prerequisite Site is configured with at least one course LTI Test tool is installed as a site external tool: Log in as an administrator Navigate to Site Administration > Plugins > External tool > Manage tools Click on configure a tool manually Fill the form as follow: Tool name: LTI Test Tool Tool url: https://lti.tools/test/tp.php Consumer key: any value would do Shared secret: secret Click on ‘Show more’ Check Content-Item message Change the 'Privacy' setting ‘Accept grades from the tool’ to 'Always'. Save changes. Test 1 - Always create a gradebook column In this test we verify that when an app is configured to always create a gradebook column for each link a gradebook column will always be created, regardless whether the content item contains a gradebook column definition or not. As instructor, log to a course Turn editing ON Click Add an activity or resource and select external tool On the Add external tool page, select LTI Test tool for preconfigured tool Click on Select Content In the modal: Click content-item button Select LTI Launch (without gradebook column definition) At the bottom of the page, click return selection When the modal is closed, verify: Grade section is visible Expand the grade section Maximum Score: 100 Expand Common module settings Click on ‘Show more’ Verify id-number is empty Click on Select Content In the modal: Click content-item button Select LTI Launch 2 (it contains a gradebook definition) At the bottom of the page, click return selection When the modal is closed, verify: Grade section is visible Expand the grade section Maximum Score: 50 Expand Common module settings Click show advanced Verify id-number has a value starting with a- Test 2 - Delegate to Teacher In this test we verify that when an app is configured to set or not a gradebook column on a per link bases, a gradebook column will always be enabled and populated only if the content item contains a gradebook column. Log in as the admin. Edit the tool created at the start of the testing instructions (in the Prerequisites). Change the 'Privacy' setting ‘Accept grades from the tool’ to 'Delegate to teacher'. Save changes. As instructor, log to a course Turn editing ON Click Add an activity or resource and select external tool On the Add external tool page, select LTI Test tool for preconfigured tool Click on Select Content In the modal: Click content-item button Select LTI Launch (without gradebook column definition) At the bottom of the page, click return selection When the modal is closed, verify: Grade section is not visible Expand Common module settings Click on ‘Show more’ Verify id-number is empty Click on Select Content In the modal: Click content-item button Select LTI Launch 2 (it contains a gradebook definition) At the bottom of the page, click return selection When the modal is closed, verify: Grade section is visible Expand the grade section Maximum Score: 50 Verify id-number has a value starting with a- Test 3 - Never create a gradebook column In this test we verify that when an app is configured to never allow a gradebook column, a gradebook column will not be enabled and populated even if the content item does contain a gradebook column. Log in as the admin. Edit the tool created at the start of the testing instructions (in the Prerequisites). Change the 'Privacy' setting ‘Accept grades from the tool’ to 'Never'. Save changes. As instructor, log to a course Turn editing ON Click Add an activity or resource and select external tool On the Add external tool page, select LTI Test tool for preconfigured tool Click on Select Content In the modal: Click content-item button Select LTI Launch 2 (contains a gradebook column) At the bottom of the page, click return selection When the modal is closed, verify: Grade section is not visible Expand Common module settings Click on ‘Show more’ Verify id-number is empty.
    • Affected Branches:
      MOODLE_34_STABLE
    • Fixed Branches:
      MOODLE_35_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-61651_master

      Description

      The LTI Deep Linking specifications allow by including a line item definition within the link the tool to return gradable LTI links i.e. links for which a gradebook column should be created . See: https://www.imsglobal.org/specs/lticiv1p0/specification-3

      Moodle should use this information to pre-populate the Grade section so that:

      Assuming the tool has Accept grades from the tool set to Delegate to instructor
      As an instructor,
      When I use Select Content to add an external tool link,
      If the content I selected is graded,
      Then on return on the External Tool page:
      Privacy: Accept grades from the tool is checked
      Grade: type is point and set maximum grade the value passed by the tool for that activity
      I can then decide to change those values or uncheck the Accepts grades from tools

      Implementation details:

      current version of the spec offers 2 parameters for max score: totalMaximum and normalMaximum. Use totalMaximum if present.
      if assignedActivity.activityId is present, it should be persisted as grade_item.idnumber (this is the resourceId from the Assignment and Grade services - MDL-60416

        Attachments

        1. 2.PNG
          2.PNG
          94 kB
        2. Capture.PNG
          Capture.PNG
          44 kB

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                17/May/18

                Time Tracking

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 41 minutes
                41m