diff --git a/app/controllers/admin/courses.php b/app/controllers/admin/courses.php index e1c53e7dbd958c72a632d2be9903499591c61c16..05e59f6c6c1fb0b6319956a777f0781a9a7ba5b5 100644 --- a/app/controllers/admin/courses.php +++ b/app/controllers/admin/courses.php @@ -486,6 +486,13 @@ class Admin_CoursesController extends AuthenticatedController break; case 20: //Notiz break; + case 21: //Mehrfachzuordnung Studienbereiche + $data['buttons_top'] = '<label>' . _('Alle auswählen') . + '<input type="checkbox" data-proxyfor=".course-admin td:last-child :checkbox"></label>'; + $data['buttons_bottom'] = (string) \Studip\Button::createAccept( + _('Mehrfachzuordnung von Studienbereichen'), 'batch_assign_semtree', + ['formaction' => URLHelper::getURL('dispatch.php/admin/tree/batch_assign_semtree')]); + break; default: foreach (PluginManager::getInstance()->getPlugins('AdminCourseAction') as $plugin) { if ($GLOBALS['user']->cfg->MY_COURSES_ACTION_AREA === get_class($plugin)) { @@ -722,6 +729,11 @@ class Admin_CoursesController extends AuthenticatedController ] ); break; + case 21: //Mehrfachzuweisung Studienbereiche + $template = $tf->open('admin/courses/batch_assign_semtree'); + $template->course = $course; + $d['action'] = $template->render(); + break; default: foreach (PluginManager::getInstance()->getPlugins('AdminCourseAction') as $plugin) { if ($GLOBALS['user']->cfg->MY_COURSES_ACTION_AREA === get_class($plugin)) { diff --git a/app/views/admin/courses/batch_assign_semtree.php b/app/views/admin/courses/batch_assign_semtree.php index b28e96bb6117dce99f6337d5e4a8069ff8103262..f4161124ed0bcf64068b7d55dc60617fb15eb29c 100644 --- a/app/views/admin/courses/batch_assign_semtree.php +++ b/app/views/admin/courses/batch_assign_semtree.php @@ -4,5 +4,7 @@ */ ?> <label> - <input name="assign_semtree[]" type="checkbox" value="<?= htmlReady($course->id) ?>"> + <input name="assign_semtree[]" type="checkbox" value="<?= htmlReady($course->id) ?>" + aria-label="<?= htmlReady(sprintf(_('Veranstaltung %s mehreren Studienbereichen zuordnen'), + $course->getFullName())) ?>"> </label>