From 847a2783837c20533fcb8c35023408a9bc877276 Mon Sep 17 00:00:00 2001 From: Rasmus Fuhse <fuhse@data-quest.de> Date: Thu, 7 Apr 2022 08:18:43 +0000 Subject: [PATCH] =?UTF-8?q?Resolve=20"OER=20Campus:=20Nicht-herunterladbar?= =?UTF-8?q?e=20Inhalte=20k=C3=B6nnen=20nicht=20gel=C3=B6scht=20werden"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/oer/market/details.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/app/views/oer/market/details.php b/app/views/oer/market/details.php index b47ed0dd6aa..2c84011c11b 100755 --- a/app/views/oer/market/details.php +++ b/app/views/oer/market/details.php @@ -40,13 +40,15 @@ </ol> <? endif ?> -<? if ($url && $material['filename']) : ?> +<? if (($url && $material['filename'] || (!$material['host_id'] && ($material->isMine() || $GLOBALS['perm']->have_perm("root"))))) : ?> <div class="center bordered" style="margin-top: 20px; margin-bottom: 20px;"> - <a class="button" - href="<?= htmlReady($url) ?>" title="<?= _('Herunterladen') ?>" - download="<?= htmlReady($material['filename']) ?>"> - <div class="filename"><?= _('Herunterladen') ?></div> - </a> + <? if ($url && $material['filename']) : ?> + <a class="button" + href="<?= htmlReady($url) ?>" title="<?= _('Herunterladen') ?>" + download="<?= htmlReady($material['filename']) ?>"> + <div class="filename"><?= _('Herunterladen') ?></div> + </a> + <? endif ?> <? if ($GLOBALS['perm']->have_perm("autor")) : ?> <a class="button" -- GitLab