问题描述:"Type definition error: [simple type, class com.domain.Book]; nested exception is com.fasterxml.InvalidDefinitionException: Cannot construct instance of ample.mall.pojo.User` (no Creators, like default construct, exist): cannot deserialize from Object value (no delegate- or property-based Creator)n at [Source: (PushbackInputStream); line: 2, column: 5]",
问题现象: 添加和修改功能报错 无法通过axios.post添加数据到数据库,点击添加按钮就报错,打开瀑布流会发现资源找不到500错误
问题解决: 根据错误提示发现是domain层的实体类,经过排查发现是写了有参构造器而没有写无参构造器导致,book对象无法创建,导致添加方法没有形参传递,验证了浏览器控制台显示的资源找不到问题。
通过修改后添加功能和修改功能可以正常使用!
本文发布于:2024-02-02 00:15:44,感谢您对本站的认可!
本文链接:https://www.4u4v.net/it/170680980840116.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
留言与评论(共有 0 条评论) |