canvas-lms/app/serializers
Alexandre Trindade 549bce4115 allow course-related variable expansions for NRPS
why:
  Course-related variable expansions aren't exposed

flag=none
refs INTEROP-6600

--------------------------------------------------
Test plan
(requires the LTI 1.3 Test Tool)
--------------------------------------------------
* Activate the feature flag "LTI Deep Linking for Module Index
  Menu"

* Install a LTI Tool with the placement "module_index_menu_modal"
  using the message_type "LtiDeepLinkingRequest"

* Go to Course > Module page

* Click on the 3 dots button-menu in the top of the page and
  launch the tool

* the "Deep Linking" page should open

* add the custom variables in the "Custom Params (JSON)" field.
  Example:
```
{
   "canvas_course_endAt":"$Canvas.course.endAt",
   "canvas_course_gradePassbackSetting":"$Canvas.course.gradePassbackSetting",
   "canvas_course_hideDistributionGraphs":"$Canvas.course.hideDistributionGraphs",
   "canvas_course_id":"$Canvas.course.id",
   "canvas_course_name":"$Canvas.course.name",
   "canvas_course_previousContextIds":"$Canvas.course.previousContextIds",
   "canvas_course_previousContextIds_recursive":"$Canvas.course.previousContextIds.recursive",
   "canvas_course_previousCourseIds":"$Canvas.course.previousCourseIds",
   "canvas_course_sectionIds":"$Canvas.course.sectionIds",
   "canvas_course_sectionRestricted":"$Canvas.course.sectionRestricted",
   "canvas_course_sectionSisSourceIds":"$Canvas.course.sectionSisSourceIds",
   "canvas_course_sisSourceId":"$Canvas.course.sisSourceId",
   "canvas_course_startAt":"$Canvas.course.startAt",
   "canvas_course_workflowState":"$Canvas.course.workflowState"
}
```

* click on "Send Deep Link to Platform"

* open the assignment created to launch the tool

* in the "Decoded JWT" field, check in the JSON for the key
  "https://purl.imsglobal.org/spec/lti/claim/custom". There
  should be the requested custom variables



Change-Id: Icbe518b67dc62da7b056af31feb5be85f13b6104
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/294961
Reviewed-by: Tucker Mcknight <tmcknight@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
2022-07-07 15:35:00 +00:00
..
canvas RuboCop: Style/StringLiterals, Style/StringLiteralsInInterpolation 2021-11-25 14:03:06 +00:00
live_assessments RuboCop: Style/StringLiterals, Style/StringLiteralsInInterpolation 2021-11-25 14:03:06 +00:00
live_events add frozen_string_literal_comment to remaining app files 2021-03-30 17:51:08 +00:00
lti allow course-related variable expansions for NRPS 2022-07-07 15:35:00 +00:00
polling RuboCop: Style/SymbolArray, Style/WordArray 2021-11-23 14:30:08 +00:00
quizzes Show course paces notice on quizzes 2022-04-18 21:01:48 +00:00
quizzes_next Show course paces notice on quizzes 2022-04-18 21:01:48 +00:00
attachment_serializer.rb RuboCop: Lint/UnusedMethodArgument partial 2021-10-21 13:39:12 +00:00
developer_key_account_binding_serializer.rb add frozen_string_literal_comment to remaining app files 2021-03-30 17:51:08 +00:00
grading_period_serializer.rb RuboCop: Layout app 2021-09-22 19:35:01 +00:00
grading_period_set_serializer.rb add frozen_string_literal_comment to remaining app files 2021-03-30 17:51:08 +00:00
late_policy_serializer.rb RuboCop: Layout app 2021-09-22 19:35:01 +00:00
locked_serializer.rb RuboCop: Style/SymbolArray, Style/WordArray 2021-11-23 14:30:08 +00:00
permissions_serializer.rb add frozen_string_literal_comment to remaining app files 2021-03-30 17:51:08 +00:00
progress_serializer.rb RuboCop: Layout app 2021-09-22 19:35:01 +00:00