Skip to content

Commit

Permalink
PDF fix #372 (#373)
Browse files Browse the repository at this point in the history
  • Loading branch information
helios-ag authored Nov 21, 2019
1 parent bbe6cdc commit 9c5d0ec
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions src/Resources/views/Elfinder/summernote.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,19 @@
onlyMimes: {{ onlyMimes|raw }},
destroyOnClose : true,
getFileCallback : function(files, fm) {
window.opener.$('.summernote').summernote('editor.insertImage',files.url);
window.close();
}
if (files.mime.match('application')) {
window.opener.$('.summernote').summernote('createLink', {
text: files.name,
url: files.url,
newWindow: true
});
window.close();
}
if(files.mime.match('image')){
window.opener.$('.summernote').summernote('editor.insertImage', files.url);
window.close();
}
}
}).elfinder('instance');
});
</script>
Expand Down

0 comments on commit 9c5d0ec

Please sign in to comment.