Unsatisfied dependency expressed through bean property ‘sqlSessionFactory 报错
Unsatisfied dependency expressed through bean property ‘sqlSessionFactory 报错
·
springboot+vue+mybatis项目
背景:代码均正常
1.试了修改pom.xml文件,没生效
<!-- 添加资源--> <resources> <resource> <directory>src/main/resources</directory> <!-- src/main/resources下的指定资源放行 --> <includes> <include>**/*.properties</include> <include>**/*.yml</include> <include>**/*.xml</include> </includes> <filtering>false</filtering> </resource> </resources>
2.修改properties文件有效,*.xml 改为 *.Mapper
mybatis.mapper-locations=classpath:mapper/*.xml
改为:
mybatis.mapper-locations=classpath:mapper/*Mapper
参考链接:
Unsatisfied dependency expressed through bean property ‘sqlSessionFactory‘报错解决_咚咚咚21的博客-CSDN博客
更多推荐
已为社区贡献1条内容
所有评论(0)