o.s.w.s.h.AbstractHandlerExceptionResolver.logException - Resolved [org.springframework.http.converter.HttpMessageNotReadableException: JSON parse error: Cannot deserialize value of type java.lang.String from Object value (token JsonToken.START_OBJECT); nested exception is com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot deserialize value of type java.lang.String from Object value (token JsonToken.START_OBJECT) at [Source: (org.springframework.util.StreamUtils$NonClosingInputStream); line: 1, column: 7] (through reference chain: com.example.shopsystem.entity.Administrator[“id”])]
今天第一次用axios的post 出现了问题 原因是 id:idTest idTest 本身是一个对象 你需要.value才能取出他的值
这样写就行了



