Skip to content
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

Content object completion miscalculation #233

Closed
oliverfoster opened this issue Jun 24, 2024 · 1 comment · Fixed by #234
Closed

Content object completion miscalculation #233

oliverfoster opened this issue Jun 24, 2024 · 1 comment · Fixed by #234
Assignees

Comments

@oliverfoster
Copy link
Member

oliverfoster commented Jun 24, 2024

Subject of the issue

I made a mistake in the pr #231 , apologies.

const isComplete = this.model.get('_isComplete');
if (isComplete) return 100;
const isContentObject = this.model.isTypeGroup('contentobject');
if (isContentObject) {
return completionCalculations.calculatePercentageComplete(this.model);
}

Does not allow assessment or pages to be represented in the bar, this is as isComplete takes precedence. The function should always defer to calculatePercentageComplete for content objects.

@oliverfoster oliverfoster self-assigned this Jun 24, 2024
@oliverfoster oliverfoster moved this from New to Needs Reviewing in adapt_framework: The TODO Board Jun 24, 2024
@github-project-automation github-project-automation bot moved this from Needs Reviewing to Recently Released in adapt_framework: The TODO Board Jun 27, 2024
github-actions bot pushed a commit that referenced this issue Jun 27, 2024
## [8.0.2](v8.0.1...v8.0.2) (2024-06-27)

### Fix

* Content object progress calculations (fixes #233) (#234) ([553b37a](553b37a)), closes [#233](#233) [#234](#234)
Copy link

🎉 This issue has been resolved in version 8.0.2 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant