Skip to content

Commit

Permalink
Avoid loading the CoachClassList page if there is only one class
Browse files Browse the repository at this point in the history
  • Loading branch information
LianaHarris360 committed Dec 17, 2024
1 parent 0379629 commit 179cf20
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions kolibri/plugins/coach/assets/src/views/CoachClassListPage.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>

<CoachAppBarPage :appBarTitle="appBarTitle">
<KPageContainer v-if="!dataLoading">
<KPageContainer v-if="!dataLoading && classListPageEnabled">
<p>
<KRouterLink
v-if="userIsMultiFacilityAdmin"
Expand Down Expand Up @@ -65,7 +65,7 @@

<script>
import { mapState } from 'vuex';
import { mapState, mapGetters } from 'vuex';
import find from 'lodash/find';
import commonCoreStrings from 'kolibri/uiText/commonCoreStrings';
import urls from 'kolibri/urls';
Expand Down Expand Up @@ -93,6 +93,7 @@
},
computed: {
...mapState(['classList', 'dataLoading']),
...mapGetters(['classListPageEnabled']),
// Message that shows up when state.classList is empty
emptyStateDetails() {
if (this.isClassCoach) {
Expand Down

0 comments on commit 179cf20

Please sign in to comment.