@ GetMapping ("/test/getById/{id} ")
CommonResultLoadUserByUsername (@ PathVariable Integer id (" id "));
I want to return to the Test class directly, but the producer of the return value is CommonResult
@ GetMapping ("/test/getById/{id} ")
Test loadUserByUsername (@ PathVariable Integer id (" id "));
Producers code
@ ApiOperation (by id "query")
@ GetMapping ("/getById/{id} ")
Public CommonResultGetById (@ PathVariable Integer id (" id ")) {
Return CommonResult. Success (testService. GetById (id));
}
CodePudding user response:
Then use CommonResultCodePudding user response:
Remote feign call, return parameter must agree, you can get the data, then wrapped upCodePudding user response:
CommonResult should be defined by a common generics, inside there must be some way out data, you take the Test