flowjs / ng-flow

Flow.js html5 file upload extension on angular.js framework
http://flowjs.github.io/ng-flow/
MIT License
1.38k stars 303 forks source link

Retrieving query data #290

Open AdamJakiela opened 8 years ago

AdamJakiela commented 8 years ago

I am trying accompany an image upload with some data. As I have read the 'query' option is the best way to do this.

In my client side code I have: `$scope.files[i]["flow"].opts.headers = {Authorization: 'Basic ' + btoa(user + ':' + token)};

              $scope.files[i]["flow"].opts.testChunks = false;

              $scope.files[i]["flow"].opts.query = {"test": "test data"};

              $scope.files[i]["flow"].upload();`

My server side is a flask app. So far the upload() call hits the expected endpoint on the server and successfully uploads the file. However, I cannot for the life of me find where the query object is stored in the request.

For those who have used Flask, I have analyzed the request object associated with the upload and haven't seen the query data anywhere.

Can someone else who is familiar with flask guide me in the right direction? Likewise, if there is a better way to send up the data than the query object I am all ears.