Skip to content

Commit

Permalink
first commit for rapport changes
Browse files Browse the repository at this point in the history
  • Loading branch information
TimoBoer authored and torinfo committed Apr 1, 2024
1 parent e939eeb commit b6b0668
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 1 deletion.
2 changes: 1 addition & 1 deletion config.php
Expand Up @@ -40,7 +40,7 @@
// and logging (to /tmp/debug.log) are turned on; either of these may help you
// diagnose installation and integration issues.
global $development;
$development = false;
$development = true;

ini_set('error_reporting', 0);
if ($development) {
Expand Down
8 changes: 8 additions & 0 deletions lti_launch.php
Expand Up @@ -42,13 +42,16 @@

if (isset($_GET["template_id"])) {
$id = $_GET["template_id"];
_debug("HERE?1");
}
else if(isset($_POST["template_id"]))
{
$id = $_POST["template_id"];
// Hack for the rest of Xerte
$_GET['template_id'] = $id;
_debug("HERE?2");
}
_debug("HERE3");
if(is_numeric($id) || $id == null)
{
$tsugi_enabled = true;
Expand All @@ -68,6 +71,11 @@
if ($islti13) {
$msg = array();
$nrps = $LAUNCH->context->loadNamesAndRoles(false, $msg);
//TODO: get all emails of current users add to array
// https://gitlab.tor.nl/xerte-dashboard/dashboard/-/blob/master/index.php line 80
//add as $xerte_toolkits_site->lti_users =
_debug("pls" . print_r($nrps, true));
_debug("msg" . print_r($msg, true));
}

if ($id == null)
Expand Down
5 changes: 5 additions & 0 deletions modules/xerte/play.php
Expand Up @@ -392,6 +392,11 @@ function show_template_page($row, $datafile="", $xapi_enabled = false)
{
$tracking .= " var lti_context_name = '" . str_replace("'", "\'", $xerte_toolkits_site->lti_context_name) . "';\n";
}
if (isset($xerte_toolkits_site->lti_users))
{
$tracking .= " var lti_users = '" . str_replace("'", "\'", $xerte_toolkits_site->lti_users) . "';\n";
}
//todo if lti_users is set create js varaible
}
$tracking .= "</script>\n";
//$tracking .= "var lti_context_id = '1390'; var lti_context_name = 'Don Bosco College';\n</script>\n";
Expand Down
1 change: 1 addition & 0 deletions modules/xerte/xAPI/xttracking_xapi.js
Expand Up @@ -1947,6 +1947,7 @@ function getStatements(q, one, callback)
|| tmp.statements[x].context.extensions["http://xerte.org.uk/lti_context_id"] != context_id)) {
continue;
}
//todo add check if statemettns are from current users if userlist > 0
statements.push(tmp.statements[x]);
}
return statements;
Expand Down
1 change: 1 addition & 0 deletions src/Nottingham/wizards/en-GB/adaptiveContent.xwd
Expand Up @@ -143,6 +143,7 @@
<groupFromUrl label="Filter on group from URL" type="checkbox" defaultValue="false" optional="true" tooltip="Filter on groupname, where the groupname is extracted from the URL (group=groupname)"/>
<groupName label="Filter group name" type="TextInput" defaultValue="" wysiwyg="false" optional="true" tooltip="Filter on groupname, use this groupname, if the group is not specified on the URL (group=groupname). You have to enable filter on group from URL as well."/>
<contextFilter label="Filter on LTI context" type="checkbox" defaultValue="false" optional="true" tooltip="Filter on LTI context, where the LTI context retrieved from the LTI launch or the URL (lti_context_id=id)"/>
<contextUsersFilter label="Filter on current users" type="checkbox" defaultValue="false" optional="true" tooltip="Filter on the current users to prevent old users from appearing in results"/>
</group>

<newNodes>
Expand Down

0 comments on commit b6b0668

Please sign in to comment.