1
0
Fork 0
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:
HarveyKandola 2019-10-14 17:29:34 +01:00
parent ef5b5cdb32
commit 7c70274f5e
3 changed files with 1061 additions and 1058 deletions

View file

@ -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], {