Open Closed

Volo.Abp.Http.Client.AbpRemoteCallException: Unsupported Media Type #2803


User avatar
0
levees created
  • ABP Framework version: v5.1.4
  • UI type: Blazor
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): no
  • Exception message and stack trace:
global.js?_v=637839874300733999:10 crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
      Unhandled exception rendering component: Unsupported Media Type
Volo.Abp.Http.Client.AbpRemoteCallException: Unsupported Media Type
  • Steps to reproduce the issue:" i create two service, and identical with each other.
public interface ITempStuService : IApplicationService
{
    Task<StudentDto> CreateAsync(StudentDto input);
}
public interface IStudentAppService  : IApplicationService
{
    Task<StudentDto> CreateAsync(StudentDto getListInput);
}

but in the Blazor client App, call them, I get different results,one of them give wh 415 error. for reproduce i have simplify my code to minimal, and push to github https://github.com/mlwxxx/temp02

on blazor app home page, check the first button and got a Unsupported Media Type error.
but, the second button is work well.. I was so confused that I didn't know what i did wrong。 can you help me ?


4 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    HI,

    I will check it

  • User Avatar
    0
    levees created

    HI,

    I will check it

    期待回复。

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    Hi,

    Please make sure that the parameter names of StudentAppService and IStudentAppService are the same

  • User Avatar
    0
    levees created

    Hi,

    Please make sure that the parameter names of StudentAppService and IStudentAppService are the same

    it's working, thank you! 我再学习学习这是为什么。

Made with ❤️ on ABP v9.1.0-preview. Updated on December 05, 2024, 12:19