Sha256: a52210769f43484c8a42427e56ee6af6cd046e1b29090e005ea32b8614e8abab
Contents?: true
Size: 815 Bytes
Versions: 20
Compression:
Stored size: 815 Bytes
Contents
require_dependency "panda_pal/application_controller" module PandaPal class LtiController < ApplicationController def tool_config if PandaPal.lti_environments.empty? render plain: 'Domains must be set in lti_environments' return end platform = PandaPal.lti_options.delete(:platform) || 'canvas.instructure.com' request_url = "#{request.scheme}://#{request.host_with_port}" case platform when 'canvas.instructure.com' xml_config = LtiXml::CanvasPlatform.new(platform, request_url, main_app) when 'bridgeapp.com' xml_config = LtiXml::BridgePlatform.new(platform, request_url, main_app) else render plain: 'platform must be set under lti_options' return end render xml: xml_config.xml end end end
Version data entries
20 entries across 20 versions & 1 rubygems