adaptlearning / adapt_framework

A toolkit for creating responsive, accessible, multilanguage HTML5 e-learning courses.
https://www.adaptlearning.org/
GNU General Public License v3.0
572 stars 246 forks source link

default FW -> AT import issues - PLP settings #2841

Closed simondate closed 4 years ago

simondate commented 4 years ago

Subject of the issue/enhancement/features

When you create the framework using adapt create course the JSON for Page Level Progress isn't complete and breaks what should be a direct import into the Authoring Tool.

I propose updating the JSON so that a direct import is possible.

This could also be fixed by changing the PLP extension code to be more defensive (accommodating of incomplete JSON).

Your environment

Steps to reproduce

Tell us how to reproduce this issue.

1) create a course using adapt create course 2) Import the course into the Authoring Tool 3) Try to run the course

moloko commented 4 years ago

This could also be fixed by changing the PLP extension code to be more defensive (accommodating of incomplete JSON).

I agree and I think we should do this as well

olivermartinfoster commented 4 years ago

Could we just do the PLP defensive code and not remove the indicators from the default course?

moloko commented 4 years ago

Could we just do the PLP defensive code and not remove the indicators from the default course?

We should definitely do the defensive code but @simondate has not actually removed the indicators from the default course

simondate commented 4 years ago

As Matt said I made the JSON reflect what is currently in the pre-installed course.

I've never used this PLP functionality myself. I like having it half on and half off to show that there is a choice.

oliverfoster commented 4 years ago

Sweet, I misunderstood then. Ta :+1:

oliverfoster commented 4 years ago

do the defensive code bit

oliverfoster commented 4 years ago

@simondate what was the original error / problem / point of failure? can I have the console log or similar?

simondate commented 4 years ago

The course wouldn't run when you imported it. There was an error in the developer console that mentioned _isCompletionIndicatorEnabled

oliverfoster commented 4 years ago

As you can see from this search https://github.com/adaptlearning/adapt-contrib-pageLevelProgress/search?q=_isCompletionIndicatorEnabled&unscoped_q=_isCompletionIndicatorEnabled

https://github.com/adaptlearning/adapt-contrib-pageLevelProgress/blob/master/js/adapt-contrib-pageLevelProgress.js#L76 This is the only place _isCompletionIndicatorEnabled is referenced which would never cause and error. I cannot proceed without more info.

simondate commented 4 years ago
explorer_0rgrL1kXW2 chrome_cil1nAXnJi chrome_23JrjZmjF5 chrome_QPCa9ABEpQ

Menu loads but error shows

chrome_6ZymSp1A67

Any page with a component with the missing attribute doesn't load.