Skip to content

Commit

Permalink
basic template and selectors
Browse files Browse the repository at this point in the history
  • Loading branch information
tomlovesgithub committed Dec 6, 2024
1 parent 284c10d commit cc27254
Show file tree
Hide file tree
Showing 4 changed files with 619 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,14 @@ export default {
}
);
}
exerciseContent.push(
{
title: 'Multiple Exercise Custom Report',
link: () => {
this.$router.push({ name: 'multiple-exercise-custom-report' });
},
}
);
exerciseContent.push(
{
title: 'My favourites',
Expand Down
12 changes: 12 additions & 0 deletions src/router.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,9 @@ import ExerciseReportsCommissionerConflicts from '@/views/Exercise/Reports/Commi
// Merit list
import ExerciseReportsMeritList from '@/views/Exercise/Reports/MeritList.vue';

// Multiple Exercise Custom Report
import MultipleExerciseCustomReport from '@/views/Exercise/Reports/MultipleExerciseCustomReport.vue';

// Exercise tasks
import ExerciseTasks from '@/views/Exercise/Tasks.vue';
import ExerciseTasksIndex from '@/views/Exercise/Tasks/Index.vue';
Expand Down Expand Up @@ -1279,6 +1282,15 @@ const routes = [
return next();
},
},
{
path: '/MultipleExerciseCustomReport',
component: MultipleExerciseCustomReport,
name: 'multiple-exercise-custom-report',
meta: {
requiresAuth: true,
title: 'Multiple Exercises Custom Report',
},
},
];

const router = createRouter({
Expand Down
4 changes: 4 additions & 0 deletions src/store/exercise/collection.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ export default {
unbindDraft: firestoreAction(({ unbindFirestoreRef }) => {
return unbindFirestoreRef('draftRecords');
}),
getAll: firestoreAction(({ bindFirestoreRef }) => {
const firestoreRef = query(collection(firestore, 'exercises'));
return bindFirestoreRef('records', firestoreRef, { serialize: vuexfireSerialize });
}),
showFavourites: ({ commit }) => {
commit('updateFavourites', true);
commit('updateArchived', false);
Expand Down
Loading

0 comments on commit cc27254

Please sign in to comment.