This extension introduces a new Adapt event course:reset
. Triggering the event will set the course _isComplete to false and also all of the children.
From your Adapt folder run:
$ adapt install courseReset
adapt-courseReset also supports auto-hooking into the assessment plugin. To turn this on add to config.json
{
"_courseReset": {
"onFail": true
}
}
Doing this will cause the plugin to subscribe to assessment:complete
events and reset the course when the learner fails.
The default values of the compoents that are reset can be specified in the defaults
property.
{
"_courseReset": {
"defaults": {
'narrative': {
'_stage': 0
},
'accordion': {
'items': {
'_isVisited':false
}
}
}
}
}