Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named '

    xiaoxiao2025-02-03  36

    ssm分页查询出现错误:

    org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getter for property named 'shopCondition' in 'class com.lemon.entity.Shop'

    Caused by: org.apache.ibatis.reflection.ReflectionException: There is no getter for property named '

    解决方法:

    在dao层 添加@Param("变量名")

    这是我的方法:

    int queryShopCount(@Param("shopCondition")Shop shopCondition);

     

     @Param指定唯一的标识,根据这个唯一标识才能取到正确的值

    最新回复(0)