有可能是DAO层在定义的时候,
参数没有加@Param(value = “”) 导致的错误(There is no getter for property )
例如这里:List selectStaffByAreaId(Long areaId);
是因为之前没有加@Param(value = “areaId”)
加了之后就正常了
List selectStaffByAreaId(@Param(value = “areaId”)Long areaId);
错误描述:
There is no getter for property named ‘areaId’ in ‘class java.lang.Long’
APPLICATION|ERROR|||2023-09-26T15:50:47.244Z|||DirectJDKLog.java:175|log||166|||Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'areaId' in 'class java.lang.Long'] with root cause|ids-busi-service-watch-local|
org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'areaId' in 'class java.lang.Long'
at org.apache.ibatis.reflection.Reflector.getGetInvoker(Reflector.java:419)