aboutsummaryrefslogtreecommitdiff
path: root/app/views/course/wiki/history.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/course/wiki/history.php')
-rw-r--r--app/views/course/wiki/history.php20
1 files changed, 20 insertions, 0 deletions
diff --git a/app/views/course/wiki/history.php b/app/views/course/wiki/history.php
index 81fde59..cbd324d 100644
--- a/app/views/course/wiki/history.php
+++ b/app/views/course/wiki/history.php
@@ -45,6 +45,16 @@
<a href="<?= $controller->versiondiff($page) ?>" data-dialog>
<?= Icon::create('log')->asImg(['class' => 'text-bottom']) ?>
</a>
+ <? if ($page->isEditable()) : ?>
+ <form action="<?= $controller->deleteversion($page) ?>"
+ method="post"
+ class="inline"
+ title="<?= _('Version löschen') ?>"
+ data-confirm="<?= _('Wirklich diese Version löschen?') ?>">
+ <?= CSRFProtection::tokenTag() ?>
+ <?= Icon::create('trash')->asInput() ?>
+ </form>
+ <? endif ?>
</td>
</tr>
<? foreach ($page->versions as $i => $version) : ?>
@@ -69,6 +79,16 @@
<a href="<?= $controller->versiondiff($page, $version->id) ?>" data-dialog>
<?= Icon::create('log')->asImg(['class' => 'text-bottom']) ?>
</a>
+ <? if ($page->isEditable()) : ?>
+ <form action="<?= $controller->deleteversion($page, $version->id) ?>"
+ method="post"
+ class="inline"
+ title="<?= _('Version löschen') ?>"
+ data-confirm="<?= _('Wirklich diese Version löschen?') ?>">
+ <?= CSRFProtection::tokenTag() ?>
+ <?= Icon::create('trash')->asInput() ?>
+ </form>
+ <? endif ?>
</td>
</tr>
<? endforeach ?>