-
Notifications
You must be signed in to change notification settings - Fork 246
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: pull data from SCORM #1040
Comments
Unfortunately it's generally just the user's name that SCORM makes available (weirdly always in military/private school-style format i.e. "Lastname, Firstname") but I think this is a great idea, it would allow for some nice personalisation of the course content to be able to refer to the user by name. Ideally this would be done in a way that allowed it to be specified in different formats and from anywhere in the JSON e.g.
Big +1 from me for this feature request. |
First stage of this is complete in that the spoor extension is now able to pull in what information SCORM makes available about the user - next stage is to make it easy to use that information within Adapt. I think we need to get this data into the |
Amazing! You really can just use {{firstname}} in the AT's text boxes to display the info (after that funky code you gave me went in the right place). Great stuff Matt! |
@moloko, should we add a |
can we have an adapt api for this? something like: JavaScript API Adapt.global("propertyName", "value"); //setter
Adapt.global("propertyName"); //getter ^ this might need to be just an object literal or a reference to our current _globals rather than a setter/getter Adapt.globals = Adapt.course.get("_globals"); //maybe? Handlebars Helper {{global "propertyName"}} ^ not sure if this should be a helper, but i don't see another way to get the globals scope into handlebars without hijacking every template or including a "get-me-globals" helper {{include_globals}}
{{_globals.user}} Handlebars.registerHelper("include_globals", function(data) {
data.root._globals = Adapt.course.get("_globals");
return "";
}) ; |
I think it needs to be something in |
Sounds fiine to me, as long as we're happy using the current globals object, we just need to expose it in the handlebars and make a quicker reference to it in on the Adapt object. Handlebars.registerHelper("include_globals", function(data) {
data.root._globals = Adapt.course.get("_globals");
return "";
}) ; and Adapt.globals = Adapt.course.get("_globals"); ? |
quick update... I am finally on the case with this! It's going to require a LOT of changes (almost every single handlebars will need to change) but expect to see the initial PR to the framework popping up next week... |
Woot! |
reopening cause this is only half-done - still need to actually get the data from SCORM into the object in `_globals' |
the .hbs templates in adapt-contrib-boxmenu also need updating |
OK I think that's everything... please review and +1 if you're happy! |
If testing, you will need to manually update adapt-contrib-vanilla to the latest MASTER |
Sweet! I can't test easily but will try and setup a new version I can play with. Thanks mr genius! EDIT Ah wait - I just need the new version of Spoor don't I - not the framework! D'oh! |
It's telling me that the 1040 version of the boxmenu is incompatible with framework 2.0.19 |
@hmaffin sorry about that, as discussed testing this sort of thing through the authoring tool is pretty tricky - best done with the framework itself really |
AFAIK this is now done; although not all the plugins have been updated to allow for this to be used absolutely everywhere - for example, you could include the user's name in the body, instruction or feedback of an MCQ but not in an MCQ option label. If you think any plugins would particularly benefit from having this added please log a separate ticket |
Desperate to have my courses pull usernames, emails. names, whatever it can get, from SCORM, such as Moodle, to both personalise and validate within the course.
Uses could include in course certificates (Moodle's are rubbish!), emailing out (see second feature request), personalising learner experience and more!
The text was updated successfully, but these errors were encountered: