我的存储库无法自动初始化

我的存储库无法自动初始化

I found in this line subjectRepository.findOne(subject) ,subjectRepository is null,My question is similar this post推荐答案@Autowired注解被语句激活:@Autowired annotation is activated by the statement:<context:component-scan base-package="base.package"/>如果你这样做,它会被初始化If u do that, it would be initialized 这篇关于使用 Spring Data JPA 时,我的存储库无法自动初始化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
08-04 21:25