Caused by: java.lang.IllegalArgumentException: Parameter Maps collection does not contain value for com.bj186.crm.pojo.User
原因分析: myBatis在写delete语句的时候,多写了一个属性
错误的代码:
<delete id="deleteUser" parameterType="Integer" parameterMap="com.bj186.crm.pojo.User">
update Users set user_status='invalid' where user_id = #{uid}
</delete>
正确的代码:
<delete id="deleteUser" parameterType="Integer">
update Users set user_status='invalid' where user_id = #{uid}
</delete>
解决方法: 将parameterMap="com.bj186.crm.pojo.User"这段代码删除掉