我正在使用cfs:ui以及所有其他cfs包来上传和显示图像。问题是,我无法获得图像显示助手的图像ID。这是代码。显示cfs:ui图像流星
Template.upload.events({
'change #exampleInput': FS.EventHandlers.insertFiles(Images, {
metadata: function (fileObj) {
return {
owner: Meteor.userId(),
pic: fileObj._id
};
},
after: function (error, fileObj) {
console.log("Inserted", fileObj._id);
}
})
});
<template name="profile">
{{#with FS.GetFile "images" metadata.pic}}
<img src="{{this.url}}">
{{/with}}
</template>
如何显示呢?