mirror of
https://github.com/wekan/wekan.git
synced 2025-12-18 08:20:12 +01:00
Attachment upload from card done, need to fix download link
This commit is contained in:
parent
05c53ca01d
commit
4dcdec0084
9 changed files with 49 additions and 27 deletions
|
|
@ -37,7 +37,15 @@ Utils = {
|
|||
let settings = {
|
||||
file: fileObj,
|
||||
streams: 'dynamic',
|
||||
chunkSize: 'dynamic'
|
||||
chunkSize: 'dynamic',
|
||||
onUploaded: function(error, fileObj) {
|
||||
console.log('after insert', Attachments.find({}).fetch());
|
||||
if (error) {
|
||||
console.log('Error while upload', error);
|
||||
} else {
|
||||
next(fileObj);
|
||||
}
|
||||
},
|
||||
};
|
||||
settings.meta = {};
|
||||
if (card.isLinkedCard()) {
|
||||
|
|
@ -51,10 +59,10 @@ Utils = {
|
|||
}
|
||||
settings.meta.userId = Meteor.userId();
|
||||
// FIXME: What is this?
|
||||
/* if (file.original) {
|
||||
/* if (file.original) {
|
||||
file.original.name = fileObj.name;
|
||||
}*/
|
||||
return next(Attachments.insert(settings, false));
|
||||
Attachments.insert(settings);
|
||||
},
|
||||
shrinkImage(options) {
|
||||
// shrink image to certain size
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue