mirror of
https://github.com/documize/community.git
synced 2025-07-19 13:19:43 +02:00
Add edit check to atatchments list view
This commit is contained in:
parent
ef5b5cdb32
commit
7c70274f5e
3 changed files with 1061 additions and 1058 deletions
|
@ -62,6 +62,9 @@ export default Component.extend(Modals, Notifier, {
|
|||
let uploadUrl = `${url}/documents/${documentId}/attachments`;
|
||||
|
||||
// Handle upload clicks on button and anything inside that button.
|
||||
// But only if user can edit this document.
|
||||
if (!this.get('canEdit')) return;
|
||||
|
||||
let sel = ['#upload-document-files ', '#upload-document-files > i'];
|
||||
for (var i=0; i < 2; i++) {
|
||||
let dzone = new Dropzone(sel[i], {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue