aboutsummaryrefslogtreecommitdiff
path: root/lib/modules/StudipModuleExtended.php
diff options
context:
space:
mode:
authorJan-Hendrik Willms <tleilax+studip@gmail.com>2025-08-07 10:13:09 +0200
committerJan-Hendrik Willms <tleilax+studip@gmail.com>2025-08-07 10:13:09 +0200
commitb1bc66f361a4dda92aba22fdd42843f619797a6c (patch)
treeecf6a08bddd1230edf7b49fc756073b4071ba169 /lib/modules/StudipModuleExtended.php
parentca3ade956dd9c9041c07cef048136fa91f5faca2 (diff)
implement performance optimizations for my courses, fixes #4693
Closes #4693 Merge request studip/studip!3724
Diffstat (limited to 'lib/modules/StudipModuleExtended.php')
-rw-r--r--lib/modules/StudipModuleExtended.php27
1 files changed, 27 insertions, 0 deletions
diff --git a/lib/modules/StudipModuleExtended.php b/lib/modules/StudipModuleExtended.php
new file mode 100644
index 0000000..c80af15
--- /dev/null
+++ b/lib/modules/StudipModuleExtended.php
@@ -0,0 +1,27 @@
+<?php
+
+interface StudipModuleExtended extends StudipModule
+{
+ /**
+ * Returns navigation objects representing this plugin
+ * in the course overview table for every given course or institute.
+ * The navigation object's title will not be shown,
+ * only the image (and its associated attributes like 'title')
+ * and the URL are actually used.
+ *
+ * By convention, new or changed plugin content is indicated
+ * by a different icon and a corresponding tooltip.
+ *
+ * Returning null for a course will result in a blank space, while returning no entry will render nothing.
+ *
+ * @param array $course_ids array of course or institute range ids.
+ * Only ranges where the module is active should be given
+ * @param string|null $user_id the user to get the navigation for
+ *
+ * @return Navigation[] associative array per given course, containing a navigation or null,
+ * where the course_id is the key: ['course_id_1' => $nav1, 'course_id_2' => $nav2, 'course_id_3' => null, ...].
+ *
+ */
+ public function getManyIconNavigation(array $course_ids, ?string $user_id = null): array;
+
+}