Browse Source

Merge public link icon check

tags/v3.0
Michael Gapczynski 13 years ago
parent
commit
594532da9a
1 changed files with 5 additions and 14 deletions
  1. 5
    14
      apps/files_sharing/js/share.js

+ 5
- 14
apps/files_sharing/js/share.js View File

@@ -12,20 +12,11 @@ $(document).ready(function() {
success: function(users) {
if (users.length > 0) {
icon = OC.imagePath('core', 'actions/shared');
} else {
icon = OC.imagePath('core', 'actions/share');
}
}
});
$.ajax({
type: 'GET',
url: OC.linkTo('files_publiclink', 'ajax/getlink.php'),
dataType: 'json',
data: 'path='+file,
async: false,
success: function(link) {
if (link.length > 0) {
icon = OC.imagePath('core', 'actions/public');
$.each(users, function(index, row) {
if (row.uid_shared_with == 'public') {
icon = OC.imagePath('core', 'actions/public');
}
});
} else {
icon = OC.imagePath('core', 'actions/share');
}

Loading…
Cancel
Save