mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-30 04:29:21 +03:00
#89 added downloading of decrypted attachments
This commit is contained in:
parent
4a1c3beb78
commit
25a786d584
5 changed files with 36 additions and 30 deletions
|
|
@ -21,7 +21,6 @@ export class AttachmentModel extends AbstractModel {
|
|||
this.fileNameExt = '';
|
||||
this.fileType = FileType.Unknown;
|
||||
this.friendlySize = '';
|
||||
this.isInline = false;
|
||||
this.isLinked = false;
|
||||
this.isThumbnail = false;
|
||||
this.cid = '';
|
||||
|
|
@ -29,8 +28,13 @@ export class AttachmentModel extends AbstractModel {
|
|||
this.download = '';
|
||||
this.folder = '';
|
||||
this.uid = '';
|
||||
this.url = '';
|
||||
this.mimeIndex = '';
|
||||
this.framed = false;
|
||||
|
||||
this.addObservables({
|
||||
isInline: false
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -124,14 +128,14 @@ export class AttachmentModel extends AbstractModel {
|
|||
* @returns {string}
|
||||
*/
|
||||
linkDownload() {
|
||||
return attachmentDownload(this.download);
|
||||
return this.url || attachmentDownload(this.download);
|
||||
}
|
||||
|
||||
/**
|
||||
* @returns {string}
|
||||
*/
|
||||
linkPreview() {
|
||||
return serverRequestRaw('View', this.download);
|
||||
return this.url || serverRequestRaw('View', this.download);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue