diff options
author | Michael Gapczynski <GapczynskiM@gmail.com> | 2011-08-09 11:00:14 -0400 |
---|---|---|
committer | Michael Gapczynski <GapczynskiM@gmail.com> | 2011-08-09 11:00:14 -0400 |
commit | 7c840e9bbb2adf3d2f3f32e20161b0aadf2b66fd (patch) | |
tree | e345355184e1e27cc28625c0b9f90bfce8274b2c /apps/files_sharing/js | |
parent | c6544429016f55440073161f37d905383b1a76c9 (diff) | |
download | nextcloud-server-7c840e9bbb2adf3d2f3f32e20161b0aadf2b66fd.tar.gz nextcloud-server-7c840e9bbb2adf3d2f3f32e20161b0aadf2b66fd.zip |
Remove users and groups from the select form that have already been shared with
Diffstat (limited to 'apps/files_sharing/js')
-rw-r--r-- | apps/files_sharing/js/share.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/files_sharing/js/share.js b/apps/files_sharing/js/share.js index f914f8da175..38738892b8f 100644 --- a/apps/files_sharing/js/share.js +++ b/apps/files_sharing/js/share.js @@ -140,6 +140,7 @@ function createShareDropdown(filenames, files) { if (users) { var list = "<ul>"; $.each(users, function(index, row) { + $('#uid_shared_with option[value="'+row.uid_shared_with+'"]').remove(); if (typeof(index) == 'string') { // TODO typeof not always working, group together users that have parent folders shared with them list += "<li>Parent folder "+index.substr(0, index.lastIndexOf('-'))+" shared with "+row.uid_shared_with+"</li>"; @@ -158,6 +159,7 @@ function createShareDropdown(filenames, files) { }); list += "</ul>"; $(list).appendTo('#shared_list'); + $('#uid_shared_with').trigger('liszt:updated'); } }); $.getJSON(OC.linkTo('files_publiclink', 'ajax/getlink.php'), { path: files }, function(token) { |