0
dev03 created
- ABP Framework version: v4.0.2
- UI type: Angular
- DB provider: MongoDB
- Tiered (MVC) or Identity Server Separated (Angular): yes
- Exception message and stack trace:
- Steps to reproduce the issue:
I tried to upload a file using IFormFile, but an error occurred when generating the proxy, See this:
Did I miss something? The API like this:
Found an issue on github: https://github.com/abpframework/abp/issues/6384
12 Answer(s)
-
0
hi coeusli
You should use
IRemoteStreamContent
in app service. Then follow https://github.com/abpframework/abp/issues/6384#issuecomment-739245736 -
0
-
0
hi dev02
What is your angular code that call this method?
-
0
-
0
-
0
You need to pass the file in the request body before v4.3.
example:
var settings = { "url": "https://localhost:44362/api/upload-file", "method": "POST", "headers": { "Content-Type": "image/png" }, "data": "<file contents here>" }; $.ajax(settings).done(function (response) { console.log(response); });
You can use
FormData
after v4.3. https://github.com/abpframework/abp/pull/8302 -
0
How can Ajax Data pass arguments without using FormData?
-
0
This question has been automatically marked as stale because it has not had recent activity.
-
0
-
1
-
1