aboutsummaryrefslogtreecommitdiff
path: root/app/views/admin/plugin/activation-error-form.php
blob: 30764171cee45c44aee33928f6a2aca4c2ca08fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<?php
/**
 * @var Admin_PluginController $controller
 * @var array $memory
 * @var array $errors
 */
?>
<?php
$aggregated = array_sum($memory);
if (!$aggregated) {
    $question = _('Markierte Plugins dennoch deaktivieren');
} elseif ($aggregated === count($memory)) {
    $question = _('Markierte Plugins dennoch aktivieren');
} else {
    $question = _('Markierte Plugins dennoch aktivieren bzw. deaktivieren');
}
?>

<form action="<?= $controller->url_for('admin/plugin/save') ?>" method="post">
    <input type="hidden" name="studip_ticket" value="<?= get_ticket() ?>">
    <input type="hidden" name="force" value="1">

    <?= _('Die folgenden Fehler sind aufgetreten:') ?>
    <div class="messagebox_details">
        <ul>
        <? foreach ($errors as $plugin_id => $error): ?>
            <li>
                <label>
                    <input type="checkbox" name="enabled_<?= $plugin_id ?>"
                           value="<?= (int) $memory[$plugin_id] ?>">
                    <?= htmlReady($error) ?>
                </label>
            </li>
        <? endforeach; ?>
        </ul>
    </div>

    <?= Studip\Button::create($question) ?>
</form>