diff options
| author | Jan-Hendrik Willms <tleilax+github@gmail.com> | 2021-07-22 16:07:19 +0200 |
|---|---|---|
| committer | Jan-Hendrik Willms <tleilax+github@gmail.com> | 2021-07-22 16:19:12 +0200 |
| commit | a3da1483a9e689846179159355badfec8073dbec (patch) | |
| tree | 770dcca6bdf5f6f2a11b0e7fcbbeda6919a3fc52 /lib/modules/FeedbackModule.class.php | |
current code from svn, revision 62608
Diffstat (limited to 'lib/modules/FeedbackModule.class.php')
| -rw-r--r-- | lib/modules/FeedbackModule.class.php | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/lib/modules/FeedbackModule.class.php b/lib/modules/FeedbackModule.class.php new file mode 100644 index 0000000..99be4e5 --- /dev/null +++ b/lib/modules/FeedbackModule.class.php @@ -0,0 +1,68 @@ +<?php + +/** + * FeedbackModule.class.php - Feedback Elements for Stud.IP as Module. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * @author Nils Gehrke <nils.gehrke@uni-goettingen.de> + * @license https://www.gnu.org/licenses/gpl-2.0.html GPL version 2 + */ +class FeedbackModule extends CorePlugin implements StudipModule, SystemPlugin +{ + /** + * {@inheritdoc} + */ + public function getInfoTemplate($course_id) + { + return null; + } + + /** + * {@inheritdoc} + */ + public function getIconNavigation($course_id, $last_visit, $user_id) + { + return null; + } + + /** + * {@inheritdoc} + */ + public function getTabNavigation($course_id) + { + if (Feedback::hasAdminPerm($course_id)) { + $navigation = new Navigation(_('Feedback')); + $navigation->addSubNavigation('index', new Navigation(_('Übersicht'), 'dispatch.php/course/feedback')); + return ['feedback' => $navigation]; + } + } + /** + * {@inheritdoc} + */ + public function getMetadata() + { + return [ + 'summary' => _('Einholen von Feedback zu Inhaltselementen'), + 'description' => _('Ermöglicht das Anlegen von Feedback-Elementen an verschiedenen Inhalten, sodass Nutzer dort ein Feedback zum Inhalt geben können. Dies kann aus einer Punkt- bzw. Sternbewertung bestehen oder nur aus einem Kommentar.'), + 'category' => _('Kommunikation und Zusammenarbeit'), + 'keywords' => _('Anlegen von Feedback-Elementen an verschiedenen Stellen; Auswahl verschiedener Feedback-Modi, wie Sternbewertung; Übersicht über alle Feedback-Elemente einer Veranstaltung'), + 'icon' => Icon::create('star', Icon::ROLE_INFO), + 'screenshots' => [ + 'path' => 'assets/images/plus/screenshots/Feedback', + 'pictures' => [ + ['source' => 'FeedbackIndex.png', 'title' => 'Übersichtsseite des Feedbacktools'], + ['source' => 'FeedbackAnDatei.png', 'title' => 'Inhaltselement an einer Datei'] + ] + ] + ]; + } + + public function isActivatableForContext(Range $context) + { + return $context->getRangeType() === 'course'; + } +} |
