Hello everyone,
I have defined an uploader in my form, like below:
{
view: “uploader”, upload: endPoints.promoters.postPromoterImage,
id: “image”, name: “image”, autosend:false,
value: locale(“promoters.promoterWindowAddImageButton”)
}
and I have a function which i invoke on save button to upload the image
var saveNewPromoter = function(){
$$("image").send(function(response){
var file = $$("image").files;
console.log(file.getFirstId());
console.log(file.getItem(file.getFirstId()).status);
console.log(file.getItem(file.getFirstId()).name);
});
};
The first time i hit save button file gets uploaded and is saved in my amazon s3 bucket and I return the uploaded image file’s url as string, but the call back function of uploader doesn’t get invoked.
I can’t figure what am i missing here.
Thank you in advance,
Milad