diff options
author | Brice Maron <brice@bmaron.net> | 2012-05-08 22:07:14 +0000 |
---|---|---|
committer | Brice Maron <brice@bmaron.net> | 2012-05-08 22:07:14 +0000 |
commit | fae1ce4ea76e5e4db638e549f2dae70c4125acac (patch) | |
tree | 0215024960016883aaf1b4248ffe3bcc3db8cd91 /apps/files/js | |
parent | c1490239e53a30c27e8512f7a04664c155b9e144 (diff) | |
download | nextcloud-server-fae1ce4ea76e5e4db638e549f2dae70c4125acac.tar.gz nextcloud-server-fae1ce4ea76e5e4db638e549f2dae70c4125acac.zip |
Correct file move by dropping on folder
Diffstat (limited to 'apps/files/js')
-rw-r--r-- | apps/files/js/files.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/apps/files/js/files.js b/apps/files/js/files.js index 2dce00035e1..4b4e96b949e 100644 --- a/apps/files/js/files.js +++ b/apps/files/js/files.js @@ -569,16 +569,16 @@ var dragOptions={ var folderDropOptions={ drop: function( event, ui ) { var file=ui.draggable.parent().data('file'); - var target=$(this).text().trim(); + var target=$(this).find('.nametext').text().trim(); var dir=$('#dir').val(); $.ajax({ url: OC.filePath('files', 'ajax', 'move.php'), - data: "dir="+encodeURIComponent(dir)+"&file="+encodeURIComponent(file)+'&target='+encodeURIComponent(dir)+'/'+encodeURIComponent(target), - complete: function(data){boolOperationFinished(data, function(){ - var el = $('#fileList tr').filterAttr('data-file',file).find('td.filename'); - el.draggable('destroy'); - FileList.remove(file); - });} + data: "dir="+encodeURIComponent(dir)+"&file="+encodeURIComponent(file)+'&target='+encodeURIComponent(dir)+'/'+encodeURIComponent(target), + complete: function(data){boolOperationFinished(data, function(){ + var el = $('#fileList tr').filterAttr('data-file',file).find('td.filename'); + el.draggable('destroy'); + FileList.remove(file); + });} }); } } |