Skip to content
Snippets Groups Projects
Commit 2baa7664 authored by Moritz Strohm's avatar Moritz Strohm Committed by Jan-Hendrik Willms
Browse files

TIC #608

Merge request studip/studip!421
parent 80a425fb
No related branches found
No related tags found
No related merge requests found
Showing
with 26 additions and 26 deletions
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
</a> </a>
</td> </td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($step->name) ?>
<? $actionMenu->addLink( <? $actionMenu->addLink(
$controller->url_for("admin/coursewizardsteps/edit/{$step->id}"), $controller->url_for("admin/coursewizardsteps/edit/{$step->id}"),
_('Schritt bearbeiten'), _('Schritt bearbeiten'),
......
...@@ -45,7 +45,7 @@ ...@@ -45,7 +45,7 @@
<td><?= htmlReady($ilias_index) ?></td> <td><?= htmlReady($ilias_index) ?></td>
<td><?= htmlReady($ilias_config['version']) ?></td> <td><?= htmlReady($ilias_config['version']) ?></td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($ilias_config['name']) ?>
<? $actionMenu->addLink( <? $actionMenu->addLink(
$controller->url_for("admin/ilias_interface/edit_server/$ilias_index"), $controller->url_for("admin/ilias_interface/edit_server/$ilias_index"),
_('Servereinstellungen bearbeiten'), _('Servereinstellungen bearbeiten'),
......
...@@ -89,7 +89,7 @@ use Studip\Button, Studip\LinkButton; ...@@ -89,7 +89,7 @@ use Studip\Button, Studip\LinkButton;
value="<?= $plugin['position'] ?>" <? if (!$plugin['enabled']) echo 'disabled'; ?>> value="<?= $plugin['position'] ?>" <? if (!$plugin['enabled']) echo 'disabled'; ?>>
</td> </td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($plugin['name']) ?>
<? $actionMenu->addLink( <? $actionMenu->addLink(
$controller->url_for('admin/role/assign_plugin_role/' . $pluginid), $controller->url_for('admin/role/assign_plugin_role/' . $pluginid),
_('Zugriffsrechte bearbeiten'), _('Zugriffsrechte bearbeiten'),
......
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
<td class="actions" nowrap> <td class="actions" nowrap>
<? <?
$actionMenu = ActionMenu::get(); $actionMenu = ActionMenu::get()->setContext($semester->name);
$actionMenu->addLink( $actionMenu->addLink(
$controller->url_for("admin/semester/edit/{$semester->id}"), $controller->url_for("admin/semester/edit/{$semester->id}"),
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
<?= htmlReady($group->name) ?> <?= htmlReady($group->name) ?>
<? if ($tutor): ?> <? if ($tutor): ?>
<span class="actions"> <span class="actions">
<? $menu = ActionMenu::get() ?> <? $menu = ActionMenu::get()->setContext($group->name) ?>
<? $menu->addLink($controller->url_for("admin/statusgroups/editGroup/{$group->id}"), <? $menu->addLink($controller->url_for("admin/statusgroups/editGroup/{$group->id}"),
_('Gruppe bearbeiten'), Icon::create('edit'), ['data-dialog' => 'size=auto']) ?> _('Gruppe bearbeiten'), Icon::create('edit'), ['data-dialog' => 'size=auto']) ?>
<? $menu->addMultiPersonSearch( <? $menu->addMultiPersonSearch(
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<td><?= $user->avatar() ?></td> <td><?= $user->avatar() ?></td>
<td><?= htmlReady($user->name()) ?></td> <td><?= htmlReady($user->name()) ?></td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($user->user) ?>
<? $actionMenu->addLink($controller->url_for('settings/statusgruppen/', ['open' => $group->id, 'type' => 'role', 'username' => $user->user->username]), <? $actionMenu->addLink($controller->url_for('settings/statusgruppen/', ['open' => $group->id, 'type' => 'role', 'username' => $user->user->username]),
_('Benutzer in dieser Rolle bearbeiten'), _('Benutzer in dieser Rolle bearbeiten'),
Icon::create('edit', 'clickable')) ?> Icon::create('edit', 'clickable')) ?>
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
<td class="actions"> <td class="actions">
<? if ($data['files']) : ?> <? if ($data['files']) : ?>
<? <?
$actionMenu = ActionMenu::get(); $actionMenu = ActionMenu::get()->setContext($data['course']->name);
$actionMenu->addLink($controller->url_for('admin/user/list_files/' . $user['user_id'] . '/' . $data['course']->id, $params), $actionMenu->addLink($controller->url_for('admin/user/list_files/' . $user['user_id'] . '/' . $data['course']->id, $params),
_('Dateien auflisten'), _('Dateien auflisten'),
Icon::create('folder-full', 'clickable'), Icon::create('folder-full', 'clickable'),
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
<td class="actions"> <td class="actions">
<? if ($institute['files']) : ?> <? if ($institute['files']) : ?>
<? <?
$actionMenu = ActionMenu::get(); $actionMenu = ActionMenu::get()->setContext($institute['name']);
$actionMenu->addLink($controller->url_for('admin/user/list_files/' . $user['user_id'] . '/' . $institute['Institut_id'] , $params), $actionMenu->addLink($controller->url_for('admin/user/list_files/' . $user['user_id'] . '/' . $institute['Institut_id'] , $params),
_('Dateien auflisten'), _('Dateien auflisten'),
Icon::create('folder-full', 'clickable'), Icon::create('folder-full', 'clickable'),
......
...@@ -114,7 +114,7 @@ ...@@ -114,7 +114,7 @@
<td><?= htmlReady($user['auth_plugin'] === null ? _('vorläufig') : $user->auth_plugin) ?></td> <td><?= htmlReady($user['auth_plugin'] === null ? _('vorläufig') : $user->auth_plugin) ?></td>
<td class="actions" nowrap> <td class="actions" nowrap>
<? <?
$actionMenu = ActionMenu::get(); $actionMenu = ActionMenu::get()->setContext($user);
$actionMenu->addLink( $actionMenu->addLink(
$controller->url_for("admin/user/edit/{$user->id}"), $controller->url_for("admin/user/edit/{$user->id}"),
_('Nutzer bearbeiten'), _('Nutzer bearbeiten'),
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
</a> </a>
</h1> </h1>
<? if ($folder->isFileDownloadable($file->id, $user->id)): ?> <? if ($folder->isFileDownloadable($file->id, $user->id)): ?>
<?= ActionMenu::get()->addLink( <?= ActionMenu::get()->setContext($file->name)->addLink(
$file->getDownloadURL(), $file->getDownloadURL(),
_('Datei herunterladen'), _('Datei herunterladen'),
Icon::create('download', 'clickable') Icon::create('download', 'clickable')
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<?= $this->render_partial('consultation/block-description.php', ['block' => $block['block']]) ?> <?= $this->render_partial('consultation/block-description.php', ['block' => $block['block']]) ?>
</th> </th>
<th class="actions"> <th class="actions">
<?= ActionMenu::get()->addLink( <?= ActionMenu::get()->setContext(strval($block['block']))->addLink(
$controller->editURL($block['block'], 0, $page), $controller->editURL($block['block'], 0, $page),
_('Bearbeiten'), _('Bearbeiten'),
Icon::create('edit'), Icon::create('edit'),
...@@ -119,7 +119,7 @@ ...@@ -119,7 +119,7 @@
<? endif; ?> <? endif; ?>
</td> </td>
<td class="actions"> <td class="actions">
<?= ActionMenu::get()->addLink( <?= ActionMenu::get()->setContext(strval($slot))->addLink(
$controller->noteURL($block['block'], $slot, $page), $controller->noteURL($block['block'], $slot, $page),
_('Information bearbeiten'), _('Information bearbeiten'),
Icon::create('edit'), Icon::create('edit'),
......
...@@ -70,7 +70,7 @@ ...@@ -70,7 +70,7 @@
<?= formatLinks($block->room) ?> <?= formatLinks($block->room) ?>
</td> </td>
<td class="actions"> <td class="actions">
<?= ActionMenu::get()->addLink( <?= ActionMenu::get()->setContext(strval($block))->addLink(
$controller->editURL($block, 0, $page), $controller->editURL($block, 0, $page),
_('Information bearbeiten'), _('Information bearbeiten'),
Icon::create('edit'), Icon::create('edit'),
...@@ -206,7 +206,7 @@ ...@@ -206,7 +206,7 @@
<? endif; ?> <? endif; ?>
</td> </td>
<td class="actions"> <td class="actions">
<?= ActionMenu::get()->addLink( <?= ActionMenu::get()->setContext(strval($slot))->addLink(
$controller->noteURL($slot->block, $slot, $page), $controller->noteURL($slot->block, $slot, $page),
_('Information bearbeiten'), _('Information bearbeiten'),
Icon::create('edit'), Icon::create('edit'),
......
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
</a> </a>
</td> </td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($contact) ?>
<? if (Config::get()->BLUBBER_GLOBAL_MESSENGER_ACTIVATE) : ?> <? if (Config::get()->BLUBBER_GLOBAL_MESSENGER_ACTIVATE) : ?>
<? $actionMenu->addLink( <? $actionMenu->addLink(
URLHelper::getURL('dispatch.php/blubber/write_to/' . $contact->user_id), URLHelper::getURL('dispatch.php/blubber/write_to/' . $contact->user_id),
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
<td class="actions"> <td class="actions">
<? if ($has_access && !$cancelled_dates_locked): ?> <? if ($has_access && !$cancelled_dates_locked): ?>
<form action="<?= $controller->url_for("course/timesrooms/undeleteSingle/{$date->id}/1") ?>" method="post"> <form action="<?= $controller->url_for("course/timesrooms/undeleteSingle/{$date->id}/1") ?>" method="post">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($date) ?>
<? $actionMenu->addButton('restore_date', _('Termin wiederherstellen'), Icon::create('trash+decline'), <? $actionMenu->addButton('restore_date', _('Termin wiederherstellen'), Icon::create('trash+decline'),
['data-confirm' => _('Diesen Termin wiederherstellen?')]) ?> ['data-confirm' => _('Diesen Termin wiederherstellen?')]) ?>
<?= $actionMenu->render() ?> <?= $actionMenu->render() ?>
......
...@@ -49,7 +49,7 @@ $dialog_url = $show_raumzeit ...@@ -49,7 +49,7 @@ $dialog_url = $show_raumzeit
<? endif ?> <? endif ?>
</td> </td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($date) ?>
<? $filecount = count($date->getAccessibleFolderFiles($GLOBALS['user']->id)['files']); ?> <? $filecount = count($date->getAccessibleFolderFiles($GLOBALS['user']->id)['files']); ?>
<? if ($has_access): ?> <? if ($has_access): ?>
<? $actionMenu->addLink($dialog_url, _('Termin bearbeiten'), Icon::create('edit'), ['data-dialog' => '']) ?> <? $actionMenu->addLink($dialog_url, _('Termin bearbeiten'), Icon::create('edit'), ['data-dialog' => '']) ?>
......
...@@ -93,7 +93,7 @@ ...@@ -93,7 +93,7 @@
</td> </td>
<td class="actions"> <td class="actions">
<?php <?php
$actionMenu = ActionMenu::get(); $actionMenu = ActionMenu::get()->setContext($feedback->question);
$actionMenu->addLink( $actionMenu->addLink(
$controller->link_for('course/feedback/edit_form/' . $feedback->id), $controller->link_for('course/feedback/edit_form/' . $feedback->id),
_('Feedback-Element bearbeiten'), _('Feedback-Element bearbeiten'),
......
...@@ -96,7 +96,7 @@ ...@@ -96,7 +96,7 @@
</td> </td>
<td><?= $module->getModuleTypeName() ?></td> <td><?= $module->getModuleTypeName() ?></td>
<td class="actions"> <td class="actions">
<?= ActionMenu::get()->addButton( <?= ActionMenu::get()->setContext($module->getTitle())->addButton(
'view', 'view',
_('Info'), _('Info'),
Icon::create('info-circle'), Icon::create('info-circle'),
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<? endif ?> <? endif ?>
<td><?=$module->getModuleTypeName()?></td> <td><?=$module->getModuleTypeName()?></td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($module->getTitle()) ?>
<? if (! $module->is_offline) $actionMenu->addButton( <? if (! $module->is_offline) $actionMenu->addButton(
'view', 'view',
_('Info'), _('Info'),
...@@ -97,7 +97,7 @@ ...@@ -97,7 +97,7 @@
</td> </td>
<td><?=_('ILIAS-Kurs')?></td> <td><?=_('ILIAS-Kurs')?></td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext(sprintf(_('Kurs in %s'), $ilias->getName())) ?>
<? $actionMenu->addButton( <? $actionMenu->addButton(
'start', 'start',
_('In ILIAS anzeigen'), _('In ILIAS anzeigen'),
......
...@@ -111,7 +111,7 @@ ...@@ -111,7 +111,7 @@
]) ?> ]) ?>
</td> </td>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($fullname) ?>
<? $actionMenu->addLink( <? $actionMenu->addLink(
$controller->url_for('course/members/add_comment/' . $accept['user_id']), $controller->url_for('course/members/add_comment/' . $accept['user_id']),
_('Bemerkung hinzufügen'), _('Bemerkung hinzufügen'),
......
...@@ -128,7 +128,7 @@ ...@@ -128,7 +128,7 @@
<? endif ?> <? endif ?>
<td class="actions"> <td class="actions">
<? $actionMenu = ActionMenu::get() ?> <? $actionMenu = ActionMenu::get()->setContext($fullname) ?>
<? if ($is_tutor) : ?> <? if ($is_tutor) : ?>
<? $actionMenu->addLink( <? $actionMenu->addLink(
$controller->url_for('course/members/add_comment/' . $autor['user_id']), $controller->url_for('course/members/add_comment/' . $autor['user_id']),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment