. // // This file is part of BasicLTI4Moodle // // BasicLTI4Moodle is an IMS BasicLTI (Basic Learning Tools for Interoperability) // consumer for Moodle 1.9 and Moodle 2.0. BasicLTI is a IMS Standard that allows web // based learning tools to be easily integrated in LMS as native ones. The IMS BasicLTI // specification is part of the IMS standard Common Cartridge 1.1 Sakai and other main LMS // are already supporting or going to support BasicLTI. This project Implements the consumer // for Moodle. Moodle is a Free Open source Learning Management System by Martin Dougiamas. // BasicLTI4Moodle is a project iniciated and leaded by Ludo(Marc Alier) and Jordi Piguillem // at the GESSI research group at UPC. // SimpleLTI consumer for Moodle is an implementation of the early specification of LTI // by Charles Severance (Dr Chuck) htp://dr-chuck.com , developed by Jordi Piguillem in a // Google Summer of Code 2008 project co-mentored by Charles Severance and Marc Alier. // // BasicLTI4Moodle is copyright 2009 by Marc Alier Forment, Jordi Piguillem and Nikolas Galanis // of the Universitat Politecnica de Catalunya http://www.upc.edu // Contact info: Marc Alier Forment granludo @ gmail.com or marc.alier @ upc.edu. /** * This file defines the global lti administration form * * @package mod_lti * @copyright 2009 Marc Alier, Jordi Piguillem, Nikolas Galanis * marc.alier@upc.edu * @copyright 2009 Universitat Politecnica de Catalunya http://www.upc.edu * @author Marc Alier * @author Jordi Piguillem * @author Nikolas Galanis * @author Chris Scribner * @copyright 2015 Vital Source Technologies http://vitalsource.com * @author Stephen Vickers * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ defined('MOODLE_INTERNAL') || die; /* * @var admin_settingpage $settings */ $modltifolder = new admin_category('modltifolder', new lang_string('pluginname', 'mod_lti'), $module->is_enabled() === false); $ADMIN->add('modsettings', $modltifolder); $settings->visiblename = new lang_string('manage_tools', 'mod_lti'); $ADMIN->add('modltifolder', $settings); $ADMIN->add('modltifolder', new admin_externalpage('ltitoolproxies', get_string('manage_tool_proxies', 'lti'), new moodle_url('/mod/lti/toolproxies.php'))); foreach (core_plugin_manager::instance()->get_plugins_of_type('ltisource') as $plugin) { /* * @var \mod_lti\plugininfo\ltisource $plugin */ $plugin->load_settings($ADMIN, 'modltifolder', $hassiteconfig); } $toolproxiesurl = new moodle_url('/mod/lti/toolproxies.php'); $toolproxiesurl = $toolproxiesurl->out(); if ($ADMIN->fulltree) { require_once($CFG->dirroot.'/mod/lti/locallib.php'); $configuredtoolshtml = ''; $pendingtoolshtml = ''; $rejectedtoolshtml = ''; $active = get_string('active', 'lti'); $pending = get_string('pending', 'lti'); $rejected = get_string('rejected', 'lti'); // Gather strings used for labels in the inline JS. $PAGE->requires->strings_for_js( array( 'typename', 'baseurl', 'action', 'createdon' ), 'mod_lti' ); $types = lti_filter_get_types(get_site()->id); $configuredtools = lti_filter_tool_types($types, LTI_TOOL_STATE_CONFIGURED); $configuredtoolshtml = lti_get_tool_table($configuredtools, 'lti_configured'); $pendingtools = lti_filter_tool_types($types, LTI_TOOL_STATE_PENDING); $pendingtoolshtml = lti_get_tool_table($pendingtools, 'lti_pending'); $rejectedtools = lti_filter_tool_types($types, LTI_TOOL_STATE_REJECTED); $rejectedtoolshtml = lti_get_tool_table($rejectedtools, 'lti_rejected'); $tab = optional_param('tab', '', PARAM_ALPHAEXT); $activeselected = ''; $pendingselected = ''; $rejectedselected = ''; switch ($tab) { case 'lti_pending': $pendingselected = 'class="selected"'; break; case 'lti_rejected': $rejectedselected = 'class="selected"'; break; default: $activeselected = 'class="selected"'; break; } $addtype = get_string('addtype', 'lti'); $config = get_string('manage_tool_proxies', 'lti'); $addtypeurl = "{$CFG->wwwroot}/mod/lti/typessettings.php?action=add&sesskey={$USER->sesskey}"; $template = <<< EOD