From dfcef6af003615fc79c18e3c59f16432fbb77d50 Mon Sep 17 00:00:00 2001
From: Michael Bauer <michael-bauer@posteo.de>
Date: Mon, 4 Nov 2024 15:12:31 +0100
Subject: [PATCH] Implement print-method for the coursebook-print-dialog

---
 .../coursebook/CoursebookPrintDialog.vue        | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue b/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue
index 65e29f2c5..b69ab14f6 100644
--- a/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue
+++ b/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue
@@ -132,6 +132,23 @@ export default {
       this.currentGroupSelection=groups;
       console.log(groups);
     },
+    print() {
+      this.$router.push({
+        name: "alsijil.coursebook_print",
+        params: {
+          // TODO: Send & handle more than one group!
+          groupId: this.selectedGroups[0],
+        },
+        query: { 
+          cover: this.includeCover,
+          abbreviations: this.includeAbbreviations,
+          members_table: this.includeMembersTable,
+          teachers_and_subjects_table: this.includeTeachersAndSubjectsTable,
+          person_overviews: this.includePersonOverviews,
+          coursebook: this.includeCoursebook,
+        },
+      });
+    },
   },
 };
 </script>
-- 
GitLab