ÿØÿà JFIF    ÿÛ „  ( %!1"%)+...383-7(-.+  -%%--------+------------/----------------------------ÿÀ  ¶" ÿÄ     ÿÄ @    !1AQaq‘¡"±ÁÑð2’BRráS‚ñ3b¢CT²Ò #cÿÄ    ÿÄ '   1!AQ2a"‘±#ÿÚ   ? ò(/p‘—–¢·,M|¯G»R£üešT. ôŸEoCFñ‡ 4ÔkåóxR|µÁ¨ÓDà!Ç´µ˜‡p ÍQ‹§!þž^õWsŒy  åÁ§$á«%ºq˜™JyyË0y«^Ϗ -3ÃÏËÈ£Æ\P’ä„s&•‹Üs üô'àWt¹pñCp$bÚF`·7.^)¾!)ÒÙ˜–ÅÏš^h¾ø³·ìe±ŒaeÖ—Í,e=B}Jéߦ$$½—šÙÜCC¯¶è8β–Åkèwx LÉngT±æ¹£Ócœ¿Í/©Éÿ ‰ÚCÒ­mq;Tt¶–}0"zÖPcd1š­¤tˆ„ÐÓâqú[™öUCŠ2޿د­É(¸ßúçšmW,Ò ºf‹Ån™ÄLêÁ8üÁkÁ€L¥ÍuJ1œôrÂSŒÓöt!7EUíïb)AËi¬â-ÙHk8òÁiXYwÅ)O^"ÇØriÛô{»wRUKÙÏÚlÓ¬€‚’שT ] ªb—ÊîKC^×M“xùäñz¬zJ× {4[¹M'IÆeH1LCWÕ]œûº WDæà°OÅ‚¹c²ÞuA–rL`HšpCez‡V’— Ž‚Ë„–ñ­'µR0ÕÖ=À:±G»C\nÆÉ5*¢ †3šhQ4ýÒi$Õ1"Ü]¢p-q3zcQ$ªö¨¥æf›‘»´ÝÚHá„e²JÇ–iÊ:·à¬Øc5Åk»Laª*wi [0Ówk ¦a¦0Õ²ÅÅ‚T¸’³q:Æ<¹ú Ò˜Æ}2VE•Ѐp¡Ô3Úº …h³^LJºçì¥Ánó|˜ÖˆÎˆ+« ¦dø‘Mº–d\ªDðÛ„Ì×LÝ——Ð9Ç|•FèçVm™¨€™3õS–9Äå¢<̉Ìm¢±`·º˜&Z²ž Ë®D«¶»6™‰©­HÈ Àá«h­i³04æ’hxœi3ï¨(ÓL·†‹¶ËpŒ ƒÜÒ? :õdsÀ –3æÓ·Üjâ¬9—]8n¼&]I F£¼…ì–—Œ0v°LǐÅfÛ2TÖ’aµ˜N@ÖBSÏ^à´4-±°b×nÈÈœÆD=KdŒø…ÄÈK,›ÖR§fjü$^ÔÎ!„6^ s:Üun\ôkCÞò÷<—Lúl Í›G¹ÀPá¼Nc¡šÒ…ÙWͳœ±vÊáЄ×9‹P‰cEØ‘™›µŸP<×g1 º©Ø¬wiÁ^l5× I/';Ë+´Z‡ÓÄFÕp[Èð’ HÄ ó 9¬Dl4“é±Ï”V=^Hð;žLädÉa‚°Ë,#/Ž~²BÔÛ QãñQtIeórVB,ÏÂf‹4#Μc‹É3ZIÖ Œ¢¥·üxa‡Ãçè„jŠ[5 Ä!U?,3žÎ×…ðdÓ÷háŠA‰ìÄ4÷ÃÜZÃE{‰®+W\ZÍE[‰»µk»MÝ­`¢©†˜ÃV‹-f¢¡†¢a«eŠ%«Y¨©q%jâd,Ôq`) ¤¦…šˆ ¦E>0Ùb²t–Ÿ  ÷jsςҒKÈcø(é›;k(’#ôŒQ ™C> õ³M9óºÆµ¤çâ;uÀ)5>RÔ¸fÓ~Ȧ—’-$fe«"FâUˆÊwµPÏu w+"åÉó¨6s™Û9(À¨ù©hE°½†n`m~“@©›p!Vkhµ Á1šbEqqÊ@ºèl›2 –Yã%‘‚hÛ{a¶‡ÅÞM²¬çL34®Çl]®‹ŽØŒm'RÜe35æöˆ­Á­ cP9šeÁköo´L³Ì=p8]”‡B¶,šº|ɏdzXˆØk*ÇÚ{#ñ‰pã(€¶‡9ý'šÜ³½¯kƒ†Â’ëSOƒ•Å®H6+a¢µˆ‹Y¨b˜b+XˆÖ!°u!¢"µˆˆn2ˆ Å0Ä`Å Ô®c(ÓÜGº•Ä»Œ âWî%q.áÐÄ÷î%umÍ£+ÜQ,Vn¦-GphU¸¢X­&,Gt ·K¢ÅÅ·¥RÄÊÉbKn N­R2g$VµÕó Qr#–ÓZUÏð0ÎtÙÀœz ëöo“Îk¯n„T°"SÞ+³/…€½"ižãO%Í%&Δâ‘ËØ´IˆÓ°Ë‰ÞM3.™yçÁzit›`4C`k¢¼á!álÄï sÂ[×!¤l¾æo"ƒIÔ'@ªu)3›ô®“@Z à¾] üœ'‡4¸PÞkÁ-qÄH‰ÓÍBd´ÿ —¹°ÄA&ÊUC„öz‚‚RæŠtf¬>˜ÑidšEçÑL÷áý¡V±h§­c¿¥¨ƒ@g¼…Ýö^ÞËc.ž„æ“I[ ª+·zÐÒÚ,½Ð»¶€C›7jk$๖€Ž¾ÅÙpp¶ÍþéΤ ½ØÎŒq ñpæžÅ¥#Øâ49ÃÂK^MYV“,¶Éz_òæ:…;Õ«¦I3âJ£¤û5$7Èxün\â]Êe¯(Ÿ&Ž‹¶2<6Ćf× æ¢ƱqWı[(ÙÂŽç‚T7¨@ÈÉÍß‚ïÙ"&3TYlGށ†)†#5ŠA©^T2ÆÁ†)©†©†¤yGXÁ†©"†)©¼ÅV WS†#©]R–r‹q5ÕbâWþBh¯u+ªÅÄ×ü„nÑ^êkªÁj‰jeœWˆÕÕ`µDµ2Ì+Ä µDµµ5Ô{¤Þ0RF’H÷AÛ<ÊÁ§ ƈæ0Ñ£ê4 öÚµ[¬/1²€â<-¬šö²r×0o×w ´xÐÒË„ g01¬„åEM蛇Ã\6µE›‘fÙO k÷CºnÓ1`iîÒ² áÂ!ÑLÄÿ ³¬\õ*:M=Ç»c‹2[‰ØsÕLò\ŒK L^™üÄN\¶#» Ç\……ßïIœÉ$¸ÎñÍ®ÔHÇ Ûí/´>Li”„†g^$ 7NÍÑÑ2M2ªNg=k½Ð}Ÿl6‡ —JWˆ”ÞéT·+µ¦üÂFè¢Vs6ýÆ4»2+2IÝ9ô9®ÇGÙÇ1+Ä8;*Õ§ž½D*îÑWÚçá3Ma¤·ˆ¥t}š²Ü…Q+Æüµ8HíS”üxGéÁˆ¦Ël„éÈ 5 µÄƒ6äÜ(kIš¯S†fÖ&¸®×v|Äyˆ*禌Éù@7-®Ä[]ÎÖ¿ê`º…=:…žJVnݳvðÖKE¼‚ »mà ÷f®:Ë ™–4rð¡4` ܹçž~‹C=œ…¾Ïj|VDtK.ƒ"9 Ï ­–éXá³6WÒïIL-Ї Ç home/smkb8269/public_html/lms.smk-almanshuriyah.sch.id/enrol/lti/configure.php000064400000007737152266577650023325 0ustar00. /** * Returns the deep link resource via a POST to the platform. * * @package enrol_lti * @copyright 2021 Jake Dallimore * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ use core\http_client; use enrol_lti\local\ltiadvantage\lib\lti_cookie; use enrol_lti\local\ltiadvantage\lib\launch_cache_session; use enrol_lti\local\ltiadvantage\lib\issuer_database; use enrol_lti\local\ltiadvantage\repository\application_registration_repository; use enrol_lti\local\ltiadvantage\repository\deployment_repository; use enrol_lti\local\ltiadvantage\repository\published_resource_repository; use Packback\Lti1p3\DeepLinkResources\Resource; use Packback\Lti1p3\LtiConstants; use Packback\Lti1p3\LtiLineitem; use Packback\Lti1p3\LtiMessageLaunch; use Packback\Lti1p3\LtiServiceConnector; require(__DIR__.'/../../config.php'); require_once(__DIR__.'/lib.php'); global $CFG, $DB, $PAGE, $USER; require_once($CFG->libdir . '/filelib.php'); require_login(null, false); require_sesskey(); $launchid = required_param('launchid', PARAM_TEXT); $modules = optional_param_array('modules', [], PARAM_INT); $grades = optional_param_array('grades', [], PARAM_INT); $sesscache = new launch_cache_session(); $issdb = new issuer_database(new application_registration_repository(), new deployment_repository()); $cookie = new lti_cookie(); $serviceconnector = new LtiServiceConnector($sesscache, new http_client()); $messagelaunch = LtiMessageLaunch::fromCache($launchid, $issdb, $sesscache, $cookie, $serviceconnector); if (!$messagelaunch->isDeepLinkLaunch()) { throw new coding_exception('Configuration can only be accessed as part of a content item selection deep link '. 'launch.'); } $sesscache->purge(); // Get the selected resources and create the resource link content items to post back. $resourcerepo = new published_resource_repository(); $resources = $resourcerepo->find_all_by_ids_for_user($modules, $USER->id); $contentitems = []; foreach ($resources as $resource) { $contentitem = Resource::new() ->setUrl($CFG->wwwroot . '/enrol/lti/launch.php') ->setCustomParams(['id' => $resource->get_uuid()]) ->setTitle($resource->get_name()); // If the activity supports grading, and the user has selected it, then include line item information. if ($resource->supports_grades() && in_array($resource->get_id(), $grades)) { require_once($CFG->libdir . '/gradelib.php'); $lineitem = LtiLineitem::new() ->setScoreMaximum($resource->get_grademax()) ->setResourceId($resource->get_uuid()); $contentitem->setLineitem($lineitem); } $contentitems[] = $contentitem; } global $USER, $CFG, $OUTPUT; $PAGE->set_context(context_system::instance()); $url = new moodle_url('/enrol/lti/configure.php'); $PAGE->set_url($url); $PAGE->set_pagelayout('popup'); echo $OUTPUT->header(); $dl = $messagelaunch->getDeepLink(); $formactionurl = $messagelaunch->getLaunchData()[LtiConstants::DL_DEEP_LINK_SETTINGS]['deep_link_return_url']; echo << HTML; home/smkb8269/public_html/lms.smk-almanshuriyah.sch.id/ai/configure.php000064400000011166152267174160021764 0ustar00. /** * Configure provider instances. * * @package core_ai * @copyright 2024 Matt Porritt * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later */ require_once('../config.php'); require_login(); $context = context_system::instance(); require_capability('moodle/site:config', $context); $id = optional_param('id', 0, PARAM_INT); // If we have an id we have existing settings. $provider = optional_param('aiprovider', null, PARAM_PLUGIN); $returnurl = optional_param('returnurl', null, PARAM_LOCALURL); $title = get_string('createnewprovider', 'core_ai'); $data = []; // Handle return URL. if (empty($returnurl)) { $returnurl = new moodle_url( url: '/admin/settings.php', params: ['section' => 'aiprovider'] ); } else { $returnurl = new moodle_url($returnurl); } $data['returnurl'] = $returnurl; if ($provider) { $configs = ['aiprovider' => $provider]; $data['providerconfigs'] = $configs; } if ($id !== 0) { // If we have an id we are updating an existing provider instance. $manager = \core\di::get(\core_ai\manager::class); $providerrecord = $manager->get_provider_record(['id' => $id], MUST_EXIST); $plugin = explode('\\', $providerrecord->provider); $plugin = $plugin[0]; $configs = json_decode($providerrecord->config, true, 512, JSON_THROW_ON_ERROR); $configs['aiprovider'] = $plugin; $configs['id'] = $providerrecord->id; $configs['name'] = $providerrecord->name; $data['providerconfigs'] = $configs; $title = get_string('configureprovider', 'core_ai'); } // Initial Page setup. $PAGE->set_context($context); $PAGE->set_url('/ai/configure.php', ['id' => $id]); $PAGE->set_pagelayout('admin'); $PAGE->set_title($title); $PAGE->set_heading($title); // Explode if there are no provider plugins installed. $plugins = core_plugin_manager::instance()->get_plugins_of_type('aiprovider'); if (empty($plugins)) { throw new moodle_exception('noproviderplugins', 'core_ai'); } // Provider instance form processing. $mform = new \core_ai\form\ai_provider_form(customdata: $data); if ($mform->is_cancelled()) { $data = $mform->get_data(); if (isset($data->returnurl)) { redirect($data->returnurl); } else { redirect($returnurl); } } if ($data = $mform->get_data()) { $data = (array)$data; $manager = \core\di::get(\core_ai\manager::class); $aiprovider = $data['aiprovider']; $providername = $data['name']; unset($data->aiprovider, $data->name, $data->id, $data->returnurl, $data->updateandreturn); if ($id !== 0) { $providerinstance = $manager->get_provider_instances(['id' => $id]); $providerinstance = reset($providerinstance); $providerinstance->name = $providername; $manager->update_provider_instance( provider:$providerinstance, config: $data ); \core\notification::add( get_string('providerinstanceupdated', 'core_ai', $providername), \core\notification::SUCCESS ); } else { $classname = $aiprovider . '\\' . 'provider'; $manager->create_provider_instance( classname: $classname, name: $providername, config: $data, ); \core\notification::add( get_string('providerinstancecreated', 'core_ai', $providername), \core\notification::SUCCESS ); } redirect($returnurl); } // Page output. echo $OUTPUT->header(); // Add the provider instance form. $mform->display(); // Add the per provider action settings only if we have an existing provider. if ($id !== 0) { echo $OUTPUT->render_from_template('core_ai/admin_action_settings', []); $provider = $mform->get_customdata()['aiprovider']; $tableid = $provider . '-' . $id; // This is the table id for the action settings table. $actiontable = new \core_ai\table\aiprovider_action_management_table($tableid); $actiontable->out(); } echo $OUTPUT->footer();