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

LTI: url, custom parameters not saved on creation when type selected

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      This issue can be reproduced with #any LTI configured at the site level#. The key elements is that custom parameters are not saved when a tool is selected in the list of available tools. The steps here use a test application that sets those custom parameters using deep linking.

      pre-requisite

      1. Install ngrok to expose your moodle setup externally. Refer here for additional guidelines
      2. Have a course with an instructor.
      3. As admin install the LTI Robotest test app using the instructions found at https://robotest.theedtech.dev
      4. Tool configuration usage: Show in activity chooser and as preconfigured tool

      Test: custom parameters and url are saved when adding links using deep linking

      1. Enter a course as instructor
      2. Turn editing on
      3. Add external activity, choose Robotest app
      4. Enter Tool URL: https://robotest.theedtech.dev/deeplink?p1=rl73403
      5. Enter Custom Parameter: resource_id=rl73403
      6. Save and Return to Course
      7. Edit the created activity and verify:
        1. The tool url is https://robotest.theedtech.dev/deeplink?p1=rl73403
        2. The custom parameter is: resource_id=rl73403 

      Test: deep link for restricted user

      Here we want to test deep link flow is functioning despite the url and parameters field not on the displayed form.

      1. Create a teacher role without the capability #mod/lti:addmanualinstance (see MDL-62815)#
      2. Create a teacher with that restricted role and enroll it in a course
      3. Enter ## that course
      4. Turn editing on
      5. Add activity
      6. Select Robotest
      7. Verify the tool url input field is not visible on the page
      8. Select Content and choose a non graded item
      9. When the modal closes, click save and display
      10. Verify the test says success (url passed, params passed)
      Show
      This issue can be reproduced with #any LTI configured at the site level#. The key elements is that custom parameters are not saved when a tool is selected in the list of available tools. The steps here use a test application that sets those custom parameters using deep linking. pre-requisite Install ngrok to expose your moodle setup externally. Refer here for additional guidelines Have a course with an instructor. As admin install the LTI Robotest test app using the instructions found at https://robotest.theedtech.dev Tool configuration usage: Show in activity chooser and as preconfigured tool Test: custom parameters and url are saved when adding links using deep linking Enter a course as instructor Turn editing on Add external activity, choose Robotest app Enter Tool URL:  https://robotest.theedtech.dev/deeplink?p1=rl73403 Enter Custom Parameter: resource_id=rl73403 Save and Return to Course Edit the created activity and verify: The tool url is https://robotest.theedtech.dev/deeplink?p1=rl73403 The custom parameter is: resource_id=rl73403  Test: deep link for restricted user Here we want to test deep link flow is functioning despite the url and parameters field not on the displayed form. Create a teacher role without the capability #mod/lti:addmanualinstance (see MDL-62815 )# Create a teacher with that restricted role and enroll it in a course Enter ## that course Turn editing on Add activity Select Robotest Verify the tool url input field is not visible on the page Select Content and choose a non graded item When the modal closes, click save and display Verify the test says success (url passed, params passed)
    • Affected Branches:
      MOODLE_39_STABLE
    • Fixed Branches:
      MOODLE_39_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-68328-dlfix

      Description

      When I create an LTI tool instance for an existing site available type (selecting the type in the drop down) the url and custom parameters of the tool will not save.

        Attachments

        1. Add-tools_the-field-Preconfigured-tool-matches-value-Teaching-Tool-1-_41_png__1353×1100_.png
          Add-tools_the-field-Preconfigured-tool-matches-value-Teaching-Tool-1-_41_png__1353×1100_.png
          182 kB
        2. everything_is_saved.png
          everything_is_saved.png
          46 kB
        3. hello_robo.png
          hello_robo.png
          201 kB
        4. moodlesessionstrictannotated.png
          moodlesessionstrictannotated.png
          31 kB
        5. no_url_without_permissions.png
          no_url_without_permissions.png
          59 kB
        6. passed_yes_no.png
          passed_yes_no.png
          12 kB
        7. passed_yes_no2.png
          passed_yes_no2.png
          170 kB
        8. required_param_missing.png
          required_param_missing.png
          77 kB
        9. two_requests_detail1.png
          two_requests_detail1.png
          55 kB
        10. two_requests_detail2.png
          two_requests_detail2.png
          58 kB
        11. two_requests.png
          two_requests.png
          15 kB

          Issue Links

            Activity

              People

              Assignee:
              claudevervoort Claude Vervoort
              Reporter:
              claudevervoort Claude Vervoort
              Peer reviewer:
              Peter Dias
              Integrator:
              Eloy Lafuente (stronk7)
              Tester:
              Eloy Lafuente (stronk7)
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                15/Jun/20

                  Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 day, 6 hours, 40 minutes
                  1d 6h 40m