Picture of Renan Jon Manuel
Soft Reset assessment to retain answer
by Renan Jon Manuel - Thursday, 21 March 2019, 4:26 AM
 

Hi, Is there a way to keep the assessment answers when reopening back the page through bookmarking on a "soft" reset type setting? Im working on the legacy version of adapt framework. Thank you.

Picture of Matt Leathes
Re: Soft Reset assessment to retain answer
by Matt Leathes - Thursday, 21 March 2019, 9:57 AM
 

Yes, see the _shouldStoreResponses setting in the spoor extension.

Picture of Renan Jon Manuel
Re: Soft Reset assessment to retain answer
by Renan Jon Manuel - Monday, 25 March 2019, 2:52 AM
 

Hi Matt, thanks for answering. But _shouldStoreResponses is already set to true on my config.json, when I set "_isResetOnRevisit" to false on the assessment article setting it does store the response, but when I set it to true it doesn't.

Picture of Matt Leathes
Re: Soft Reset assessment to retain answer
by Matt Leathes - Monday, 25 March 2019, 10:17 AM
 

Yes that's right, _isResetOnRevisit controls whether the assessment resets when you navigate away from the page and back again.

In order to stop it resetting when you quit the course and resume you also need to enable _shouldStoreResponses in the spoor extension.

Picture of Renan Jon Manuel
Re: Soft Reset assessment to retain answer
by Renan Jon Manuel - Tuesday, 2 April 2019, 4:31 AM
 

Thanks Matt, sorry for the late reply, the problem was put on backlog. Anyway, yes I have already enabled the  _shouldStoreResponses in the config.json:

"_spoor": {
"_isEnabled": true,
"_tracking": {
"_requireCourseCompleted": true,
"_requireAssessmentPassed": true,
"_shouldSubmitScore": true,
"_shouldStoreResponses": true,
"_shouldRecordInteractions": true
},
"_reporting": {
"_comment": "Your options here are 'completed', 'passed', 'failed', and 'incomplete'",
"_onTrackingCriteriaMet": "completed",
"_onAssessmentFailure": "incomplete",
"_resetStatusOnLanguageChange": false
},
"_advancedSettings": {
"_showDebugWindow": false,
"_commitOnStatusChange": true,
"_timedCommitFrequency": 10,
"_maxCommitRetries": 5,
"_commitRetryDelay": 2000,
"_suppressErrors": false,
"_commitOnVisibilityChangeHidden": true
}
},


and set the _isResetOnRevisit on my article.json as soft.

"_assessment": {
"_questions": {
"_canShowModelAnswer": false,
"_canShowMarking": true,
"_canShowFeedback": true,
"_resetType": "soft"
},
"_banks": {
"_randomisation": true,
"_split": "0,0,0,1,1,1,1",
"_isEnabled": true
},
"_isResetOnRevisit": true,
"_suppressMarking": false,
"_assessmentWeight": 1,
"_includeInTotalScore": true,
"_scoreToPass": 100,
"_isPercentageBased": true,
"_attempts": -1,
"_id": "A01",
"_isEnabled": true
}

But somehow it still doesn't store the response.

Tried installing the latest version as well (cause im currently using legacy) but had the same result.

Gonna try to check the js files on the extension if I can figure this out.

Picture of Matt Leathes
Re: Soft Reset assessment to retain answer
by Matt Leathes - Tuesday, 2 April 2019, 8:52 AM
 

You still have _isResetOnRevisit set to true:

Picture of Renan Jon Manuel
Re: Soft Reset assessment to retain answer
by Renan Jon Manuel - Thursday, 4 April 2019, 1:06 AM
 

I see, I thought that it would be possible to store the answers and results page if it is set to soft.

The target behaviour is that if it is closed midway, it would reset, and if complete, it would store the answers and results. Also we have a review content button that would link back to the menu if you fail.

What I did instead was to set the resetonrevisit to false, then have the reset button link to the menu by adding a location href on the reset button:

onRetry: function() {
var state = this.model.get("_state");
var assessmentModel = Adapt.assessment.get(state.id);

this.restoreOriginalTexts();

location.href = "#/id/59e8187a03e627dd19224834";

assessmentModel.reset();
},

It worked as expected, it now stores the answer to each question on the assessment if you close the course midway, the only problem left is that after a failed completion, it would not restore the results and answers, instead it would reset the assessment upon reopening and saying yes to bookmark.

Is there a way to prevent the auto reset on reopening the assessment through bookmark? or redirect the bookmark location to the menu instead of reopening the asssessment page if it is already complete?

Picture of Matt Leathes
Re: Soft Reset assessment to retain answer
by Matt Leathes - Thursday, 4 April 2019, 11:30 AM
 
I thought that it would be possible to store the answers and results page if it is set to soft.

No, a 'soft' reset is when the component resets without resetting the 'has been completed' flag. A 'hard' reset will reset the 'has been completed' flag as well i.e. the user will be required to complete the component again.

The target behaviour is that if it is closed midway, it would reset, and if complete, it would store the answers and results.

This isn't a use-case it was really designed to accommodate. The purpose of the _shouldStoreResponses setting is mainly to:

  • allow the learner to resume an assessment if they quit part way through
  • prevent the learner from having more than the allowed number of attempts at an assessment

Regarding this:

or redirect the bookmark location to the menu instead of reopening the asssessment page if it is already complete

yes, just turn off bookmarking for the page that contains the assessment. but I'm not sure that will really work since if the learner chooses to go back into the assessment page from the menu it will still reset...