From 7b479c8b151b2accfc8c1709424a8c6a7fc7cad9 Mon Sep 17 00:00:00 2001 From: Dani Palou Date: Wed, 24 Apr 2019 13:43:10 +0200 Subject: [PATCH] MOBILE-2944 course: Hide completion for teachers --- src/core/course/components/format/core-course-format.html | 2 +- src/core/course/pages/section-selector/section-selector.ts | 3 ++- .../course-progress/core-courses-course-progress.html | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/core/course/components/format/core-course-format.html b/src/core/course/components/format/core-course-format.html index cf1712652..6a022a002 100644 --- a/src/core/course/components/format/core-course-format.html +++ b/src/core/course/components/format/core-course-format.html @@ -27,7 +27,7 @@
- + diff --git a/src/core/course/pages/section-selector/section-selector.ts b/src/core/course/pages/section-selector/section-selector.ts index f438ceef9..6186fe8ca 100644 --- a/src/core/course/pages/section-selector/section-selector.ts +++ b/src/core/course/pages/section-selector/section-selector.ts @@ -36,7 +36,8 @@ export class CoreCourseSectionSelectorPage { this.selected = navParams.get('selected'); const course = navParams.get('course'); - if (course && course.enablecompletion && course.courseformatoptions && course.courseformatoptions.coursedisplay == 1) { + if (course && course.enablecompletion && course.courseformatoptions && course.courseformatoptions.coursedisplay == 1 && + course.completionusertracked !== false) { this.sections.forEach((section) => { let complete = 0, total = 0; diff --git a/src/core/courses/components/course-progress/core-courses-course-progress.html b/src/core/courses/components/course-progress/core-courses-course-progress.html index 4e2757ebb..ed633bbac 100644 --- a/src/core/courses/components/course-progress/core-courses-course-progress.html +++ b/src/core/courses/components/course-progress/core-courses-course-progress.html @@ -30,7 +30,7 @@ - +