1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-21 14:19:43 +02:00

WIP new document UX/UI

This commit is contained in:
Harvey Kandola 2018-05-29 18:26:04 +01:00
parent 21ba55a58f
commit 36be6243ad
23 changed files with 910 additions and 4231 deletions

View file

@ -22,7 +22,7 @@ export default Component.extend({
return this.get('document.protection') !== this.get('constants').ProtectionType.Lock && this.get('permissions.documentEdit');
}),
showDialog: false,
init() {
this._super(...arguments);
this.getAttachments();
@ -82,6 +82,7 @@ export default Component.extend({
getAttachments() {
this.get('documentService').getAttachments(this.get('document.id')).then((files) => {
this.set('files', files);
this.get('onReady')(files.length);
});
},
@ -96,7 +97,7 @@ export default Component.extend({
this.set('showDialog', false);
let attachment = this.get('deleteAttachment');
this.get('documentService').deleteAttachment(this.get('document.id'), attachment.id).then(() => {
this.getAttachments();
this.set('deleteAttachment', {