diff --git a/app/locale/en.coffee b/app/locale/en.coffee index fd844fb3c..a99949080 100644 --- a/app/locale/en.coffee +++ b/app/locale/en.coffee @@ -1339,6 +1339,7 @@ unarchive_class: "unarchive class" unarchive_this_class: "Unarchive this class" no_students_yet: "This class has no students yet." + try_refreshing: "(You may need to refresh the page)" add_students: "Add Students" create_new_class: "Create a New Class" class_overview: "Class Overview" # View Class page diff --git a/app/templates/courses/teacher-class-view.jade b/app/templates/courses/teacher-class-view.jade index 11c689eea..5b12984c6 100644 --- a/app/templates/courses/teacher-class-view.jade +++ b/app/templates/courses/teacher-class-view.jade @@ -108,28 +108,36 @@ block content +copyCodes +addStudentsButton - ul.nav.nav-tabs.m-t-5(role='tablist') - - var activeTab = state.get('activeTab'); - li(class=(activeTab === "#students-tab" ? 'active' : '')) - a.students-tab-btn(href='#students-tab') - .small-details.text-center(data-i18n='teacher.students') - .tab-spacer - li(class=(activeTab === "#course-progress-tab" ? 'active' : '')) - a.course-progress-tab-btn(href='#course-progress-tab') - .small-details.text-center(data-i18n='teacher.course_progress') - .tab-spacer - li(class=(activeTab === "#enrollment-status-tab" ? 'active' : '')) - a.course-progress-tab-btn(href='#enrollment-status-tab') - .small-details.text-center(data-i18n='teacher.enrollment_status') - .tab-filler + if view.students.length > 0 + ul.nav.nav-tabs.m-t-5(role='tablist') + - var activeTab = state.get('activeTab'); + li(class=(activeTab === "#students-tab" ? 'active' : '')) + a.students-tab-btn(href='#students-tab') + .small-details.text-center(data-i18n='teacher.students') + .tab-spacer + li(class=(activeTab === "#course-progress-tab" ? 'active' : '')) + a.course-progress-tab-btn(href='#course-progress-tab') + .small-details.text-center(data-i18n='teacher.course_progress') + .tab-spacer + li(class=(activeTab === "#enrollment-status-tab" ? 'active' : '')) + a.course-progress-tab-btn(href='#enrollment-status-tab') + .small-details.text-center(data-i18n='teacher.enrollment_status') + .tab-filler - .tab-content - if activeTab === '#students-tab' - +studentsTab - else if activeTab === '#course-progress-tab' - +courseProgressTab - else - +enrollmentStatusTab + .tab-content + if activeTab === '#students-tab' + +studentsTab + else if activeTab === '#course-progress-tab' + +courseProgressTab + else + +enrollmentStatusTab + + else + .text-center.m-t-5.m-b-5 + .text-h2 + span(data-i18n="teacher.no_students_yet") + .text-h4 + span(data-i18n="teacher.try_refreshing") mixin breadcrumbs .breadcrumbs