[dart][dart-dio-next] Improve support for file uploads#9542
Merged
wing328 merged 6 commits intoOpenAPITools:masterfrom May 25, 2021
Merged
[dart][dart-dio-next] Improve support for file uploads#9542wing328 merged 6 commits intoOpenAPITools:masterfrom
wing328 merged 6 commits intoOpenAPITools:masterfrom
Conversation
* add support for filenames in multipart requests by using `MultipartFile` from dio directly * add support for binary/file body data * fixes OpenAPITools#6671 * fixes OpenAPITools#9079
jaumard
reviewed
May 21, 2021
36f5260 to
a3519b9
Compare
Contributor
|
Finally, very much needed. |
agilob
reviewed
May 21, 2021
kuhnroyal
commented
May 21, 2021
| 'date': '2020-08-11', | ||
| 'dateTime': '2020-08-11T12:30:55.123Z', | ||
| 'binary': "Instance of 'MultipartFile'", | ||
| 'binary': '[0, 1, 2, 3, 4, 5]', |
Contributor
Author
There was a problem hiding this comment.
Not sure this makes sense to send over the wire like this, but better than before in any case.
agilob
approved these changes
May 21, 2021
Member
|
@kuhnroyal please resolve the merge conflicts when you've time. Thanks. |
Member
|
CI failure not related to this change. |
premiumitsolution
pushed a commit
to premiumitsolution/openapi-generator
that referenced
this pull request
May 26, 2021
…9542) * [dart][dart-dio] Improve support for file uploads * add support for filenames in multipart requests by using `MultipartFile` from dio directly * add support for binary/file body data * fixes OpenAPITools#6671 * fixes OpenAPITools#9079 * Add and fix tests * Only use MultipartFile for body/multipart parameters * Fix test * Actually fix tests
|
I am currently using 5.2.0, but I found that the change to support MultipartFile does not seem to take effect at all. I checked the generated template and found that there was no change at all!!! |
|
dart-dio-next |
Contributor
Author
|
This should work with |
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MultipartFilefrom dio directly@jaumard @ayushin This should fix your linked issues.
PR checklist
This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master.
These must match the expectations made by your contribution.
You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example
./bin/generate-samples.sh bin/configs/java*.For Windows users, please run the script in Git BASH.
master,5.1.x,6.0.xCC @swipesight (2018/09) @jaumard (2018/09) @josh-burton (2019/12) @amondnet (2019/12) @sbu-WBT (2020/12) @kuhnroyal (2020/12) @agilob (2020/12)