解决问题:Error creating bean with name 'xxxController': Unsatisfied dependency expressed through field 'xxxService'


问题

这个问题是因为bean在注入service的时候失败了,而service的实现类和mapper没有关联起来,mapper找不到

Error creating bean with name 'xxxController': Unsatisfied dependency expressed through field 'xxxService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'xxxServiceImpl': Unsatisfied dependency expressed through field 'baseMapper'

解决办法

在mapper接口上加一个注解@Mapper

@Mapper
public interface xxxProductMapper extends BaseMapper<SmmartProduct> {

}


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2026 CODEPRJ.COM