运行springboot项目报错:Field userMapper in XX required a bean of type 'xx' that could not be found.

运行springboot项目报错:

***************************

APPLICATION FAILED TO START

***************************

Description:

Field userMapper in com.whohim.springboot.service.impl.UserServiceImpl required a bean of type ‘com.whohim.springboot.dao.UserMapper‘ that could not be found.

Action:

Consider defining a bean of type ‘com.whohim.springboot.dao.UserMapper‘ in your configuration.

Process finished with exit code 0

在项目启动类加上下面注解即可(扫描对应的mapper包)

运行springboot项目报错:Field userMapper in XX required a bean of type 'xx' that could not be found.

 

运行springboot项目报错:Field userMapper in XX required a bean of type 'xx' that could not be found.

上一篇:1024 祝iOS的每一位程序员“节日快乐”;小礼相送!


下一篇:Android应用中对webp格式图片的处理