summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorBjörn Schießle <schiessle@owncloud.com>2013-01-25 13:01:53 +0100
committerBjörn Schießle <schiessle@owncloud.com>2013-01-25 13:01:53 +0100
commit839f4bd94916d0673341528ffa8a2a7b3242bf46 (patch)
treec02c639774814be899b69409bcce479c323ba6d5 /apps/files_sharing
parentb4291f1e8e2326f5f1cbd97fa130d547f949b62d (diff)
downloadnextcloud-server-839f4bd94916d0673341528ffa8a2a7b3242bf46.tar.gz
nextcloud-server-839f4bd94916d0673341528ffa8a2a7b3242bf46.zip
show display name instead of uid in the public shared files view
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/public.php1
-rw-r--r--apps/files_sharing/templates/public.php4
2 files changed, 3 insertions, 2 deletions
diff --git a/apps/files_sharing/public.php b/apps/files_sharing/public.php
index efd977a1b6a..93f3b4da2bd 100644
--- a/apps/files_sharing/public.php
+++ b/apps/files_sharing/public.php
@@ -207,6 +207,7 @@ if ($linkItem) {
OCP\Util::addScript('files', 'fileactions');
$tmpl = new OCP\Template('files_sharing', 'public', 'base');
$tmpl->assign('uidOwner', $shareOwner);
+ $tmpl->assign('displayName', \OCP\User::getDisplayName($shareOwner));
$tmpl->assign('dir', $dir);
$tmpl->assign('filename', $file);
$tmpl->assign('mimetype', OC_Filesystem::getMimeType($path));
diff --git a/apps/files_sharing/templates/public.php b/apps/files_sharing/templates/public.php
index 647e1e08a31..13af528ce80 100644
--- a/apps/files_sharing/templates/public.php
+++ b/apps/files_sharing/templates/public.php
@@ -14,9 +14,9 @@
<a href="<?php echo link_to('', 'index.php'); ?>" title="" id="owncloud"><img class="svg" src="<?php echo image_path('', 'logo-wide.svg'); ?>" alt="ownCloud" /></a>
<div class="header-right">
<?php if (isset($_['folder'])): ?>
- <span id="details"><?php echo $l->t('%s shared the folder %s with you', array($_['uidOwner'], $_['filename'])) ?></span>
+ <span id="details"><?php echo $l->t('%s shared the folder %s with you', array($_['displayName'], $_['filename'])) ?></span>
<?php else: ?>
- <span id="details"><?php echo $l->t('%s shared the file %s with you', array($_['uidOwner'], $_['filename'])) ?></span>
+ <span id="details"><?php echo $l->t('%s shared the file %s with you', array($_['displayName'], $_['filename'])) ?></span>
<?php endif; ?>
<?php if (!isset($_['folder']) || $_['allowZipDownload']): ?>
<a href="<?php echo $_['downloadURL']; ?>" class="button" id="download"><img class="svg" alt="Download" src="<?php echo OCP\image_path("core", "actions/download.svg"); ?>" /><?php echo $l->t('Download')?></a>