springboot项目结构
由于mapper.xml分布在不同的模块中,
mybatis.mapperLocations=classpath:mapper/*.xml 不能两个模块中mapper文件夹下的xml文件不能加载
这是因为classpath只加载了一个mapper的改成
mybatis.mapperLocations=classpath*:mapper/*.xml
解决问题
springboot项目结构
由于mapper.xml分布在不同的模块中,
mybatis.mapperLocations=classpath:mapper/*.xml 不能两个模块中mapper文件夹下的xml文件不能加载
这是因为classpath只加载了一个mapper的改成
mybatis.mapperLocations=classpath*:mapper/*.xml
解决问题