angular-file-upload
angular-file-upload copied to clipboard
Upload all the files together? Not one after another
Is it possible to make all the files upload together rather than uploading one after another?
This will be a nice feature. asynchronously uploading all the files together.
+1...I'm looking for this too...Seems like it must be possible
+1 as well - I logged the the $_FILES variable in PHP and it returns only one of two files I upload.
+1
+1
+1
+1
+1
+1
+1
+1
I got a workaround: use the callback: onAfterAddingAll
// in controller:
$scope.uploader.onAfterAddingAll = function(addedItems) {
var fileItem_0 = $scope.uploader.queue[0];
// fileItem_0.filenames = fileItem_0.file.name;
// fileItem_0.filessize = fileItem_0.file.size;
var tFileItem;
var pop_times = $scope.uploader.queue.length;
for(var i=1; i<pop_times; i++){
tFileItem = $scope.uploader.queue.pop();
fileItem_0.formData.push({file: tFileItem._file});
// fileItem_0.filessize = fileItem_0.filessize + tFileItem._file.size;
// fileItem_0.filenames = fileItem_0.filenames + ' ' + tFileItem.file.name
}
// ... ready to upload
}
btw, removeAfterUpload should be set true
.
+1
+1
+1
+1
+1
@DoubleFaults the solution works. Thanks. However the upload queue list does not list all documents, but rather only one. How can this be fixed?