diff options
author | Vincent Petry <pvince81@owncloud.com> | 2014-03-05 12:43:10 +0100 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2014-03-05 12:43:10 +0100 |
commit | 2cfd875e616fa0770441a17d6f96a9f5f45e8c3f (patch) | |
tree | 612f41773820c633b8552efc1c01693cb975753c /apps/files_sharing/lib | |
parent | a8ae2f10b9a02ac50f7366de9aa7ff07c88f38ec (diff) | |
parent | 15d1df055b093ecce0c5ae52561dd73584145c7c (diff) | |
download | nextcloud-server-2cfd875e616fa0770441a17d6f96a9f5f45e8c3f.tar.gz nextcloud-server-2cfd875e616fa0770441a17d6f96a9f5f45e8c3f.zip |
Merge pull request #7012 from owncloud/display-share-owner-master
adding share owner information to the file list
Diffstat (limited to 'apps/files_sharing/lib')
-rw-r--r-- | apps/files_sharing/lib/cache.php | 3 | ||||
-rw-r--r-- | apps/files_sharing/lib/share/file.php | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/cache.php b/apps/files_sharing/lib/cache.php index 4b0da0b002d..10f2182655f 100644 --- a/apps/files_sharing/lib/cache.php +++ b/apps/files_sharing/lib/cache.php @@ -137,9 +137,12 @@ class Shared_Cache extends Cache { } else { $cache = $this->getSourceCache($folder); if ($cache) { + $parent = $this->storage->getFile($folder); $sourceFolderContent = $cache->getFolderContents($this->files[$folder]); foreach ($sourceFolderContent as $key => $c) { $sourceFolderContent[$key]['usersPath'] = 'files/Shared/' . $folder . '/' . $c['name']; + $sourceFolderContent[$key]['uid_owner'] = $parent['uid_owner']; + $sourceFolderContent[$key]['displayname_owner'] = $parent['uid_owner']; } return $sourceFolderContent; diff --git a/apps/files_sharing/lib/share/file.php b/apps/files_sharing/lib/share/file.php index ec0f368386f..5e00050fe1e 100644 --- a/apps/files_sharing/lib/share/file.php +++ b/apps/files_sharing/lib/share/file.php @@ -94,6 +94,9 @@ class OC_Share_Backend_File implements OCP\Share_Backend_File_Dependent { $file['mtime'] = $item['mtime']; $file['encrypted'] = $item['encrypted']; $file['etag'] = $item['etag']; + $file['uid_owner'] = $item['uid_owner']; + $file['displayname_owner'] = $item['displayname_owner']; + $storage = \OC\Files\Filesystem::getStorage('/'); $cache = $storage->getCache(); if ($item['encrypted'] or ($item['unencrypted_size'] > 0 and $cache->getMimetype($item['mimetype']) === 'httpd/unix-directory')) { |