Download attachments of a message as a zip archive

This commit is contained in:
Francis Lachapelle
2016-12-07 14:38:33 -05:00
parent 2a2ebd553e
commit 011fae8a65
17 changed files with 487 additions and 289 deletions
@@ -269,11 +269,15 @@
* @returns a promise of the HTTP operation
*/
Card.prototype.export = function() {
var selectedIDs;
var data, options;
selectedIDs = [ this.id ];
data = { uids: [ this.id ] };
options = {
type: 'application/octet-stream',
filename: this.$$fullname + '.ldif'
};
return Card.$$resource.download(this.pid, 'export', {uids: selectedIDs}, {type: 'application/octet-stream'});
return Card.$$resource.download(this.pid, 'export', data, options);
};
Card.prototype.$fullname = function(options) {