fix bug that prevented lti2 tools from being added
fixes PLAT-1047 test-plan: you should be able to add an lti2 tool as a module item and assignment you shoujld be able to add an lti 1 tool as a module item and assignment Change-Id: Iece31cb76096f1fa42a4358fc2a9a3f411e3b18c Reviewed-on: https://gerrit.instructure.com/55250 Tested-by: Jenkins QA-Review: August Thornton <august@instructure.com> Reviewed-by: Brad Horrocks <bhorrocks@instructure.com> Product-Review: Nathan Mills <nathanm@instructure.com>
This commit is contained in:
parent
cdefee9f8d
commit
9beb9efc70
|
@ -157,8 +157,12 @@ $(document).ready(function() {
|
|||
} else if(item_type == 'context_external_tool') {
|
||||
|
||||
var tool = $("#context_external_tools_select .tools .tool.selected").data('tool');
|
||||
var tool_type = tool ? $.underscore(tool.definition_type) : $("#add_module_item_select").val();
|
||||
var tool_id = tool ? tool.definition_id : 0
|
||||
var tool_type = 'context_external_tool';
|
||||
var tool_id = 0;
|
||||
if(tool){
|
||||
if(tool.definition_type == 'Lti::MessageHandler') { tool_type = 'lti/message_handler'}
|
||||
tool_id = tool.definition_id
|
||||
}
|
||||
var item_data = {
|
||||
'item[type]': tool_type,
|
||||
'item[id]': tool_id,
|
||||
|
|
Loading…
Reference in New Issue