Merge pull request #304 from owncloud/viewer-nostaticfileactionaccess

Use context instead of static access
This commit is contained in:
VicDeo 2014-07-09 21:30:58 +03:00
commit 71e4f3ba66

View File

@ -46,8 +46,8 @@ var odfViewer = {
} }
}, },
onEdit : function(){ onEdit : function(fileName, context){
var fileId = OCA.Files.fileActions.currentFile.parent().attr('data-id'); var fileId = context.$file.attr('data-id');
window.location = OC.linkTo('documents', 'index.php') + '#' + fileId; window.location = OC.linkTo('documents', 'index.php') + '#' + fileId;
}, },