org.thymeleaf.exeption.TemplateInputException:Error resolvin template "user/info",等问题解决方法

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/qq_37606901/article/details/89735546

这个报错的原因就是解析不到往返,那么只需要在方法上面添加 @ResponseBody就行。例如,下面是我的代码

  @RequestMapping("/info")
    @ResponseBody
    public Result<MiaoshaUser> info(Model model,MiaoshaUser user) {
        return Result.success(user);
    }

猜你喜欢

转载自blog.csdn.net/qq_37606901/article/details/89735546