diff options
author | Vincent Petry <pvince81@owncloud.com> | 2014-06-03 11:04:57 +0200 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2014-06-03 11:04:57 +0200 |
commit | 1297b2b883c447c5183a79eb6c0e0061b69aeadf (patch) | |
tree | 7613b0ec814b25294f58ee4e22647d90ba08dece /core/js/share.js | |
parent | 640fbc016dd81f6ffffb4eb404717a9dd2c2465a (diff) | |
download | nextcloud-server-1297b2b883c447c5183a79eb6c0e0061b69aeadf.tar.gz nextcloud-server-1297b2b883c447c5183a79eb6c0e0061b69aeadf.zip |
Multiple fixes to sharing overview
- scrolling to next page now correctly renders share icons
- reshareing/unsharing a reshare will now still keep "Shared by" label
Diffstat (limited to 'core/js/share.js')
-rw-r--r-- | core/js/share.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/core/js/share.js b/core/js/share.js index 4e12f35d19e..a46a17102fd 100644 --- a/core/js/share.js +++ b/core/js/share.js @@ -151,7 +151,7 @@ OC.Share={ var img = action.find('img'); var message; var recipients; - var owner; + var owner = $tr.attr('data-share-owner'); var shareFolderIcon; var image = OC.imagePath('core', 'actions/share'); // update folder icon @@ -168,16 +168,16 @@ OC.Share={ $tr.children('.filename').css('background-image', 'url(' + shareFolderIcon + ')'); } // update share action text / icon - if (hasShares) { + if (hasShares || owner) { recipients = $tr.attr('data-share-recipients'); - owner = $tr.attr('data-share-owner'); action.addClass('permanent'); message = t('core', 'Shared'); - if (owner && !recipients) { + // even if reshared, only show "Shared by" + if (owner) { message = t('files_sharing', 'Shared by {owner}', {owner: owner}); } - if (recipients) { + else if (recipients) { message = t('core', 'Shared with {recipients}', {recipients: recipients}); } action.html(' <span>'+ message + '</span>').prepend(img); |