org.springframework.beans.factory.UnsatisfiedDependencyException:解决方案
今天做项目遇到了如下问题:
简单来说就是找不到依赖,百度了很多方法都没有用。最后想着运行一下整个项目看看问题,结果报错,信息提示:Field rejectMapper in com.welfare.serviceImpl.RejectServiceImpl required a bean of type ‘com.welfare.dao.RejectMapper’ that could not be found.
明明有RejectMapper文件却没找到,解决办法是在项目启动项里加入@MapperScan(“com.welfare.dao”)注解