因为Dao层使用了MyBatisScanner 所以idea经常提示@AutoWired为null,飘红线很碍眼,所以需要调整一下idea的代码检测规范。具体如下:

Setting – File – Settings – Inspections
Idea修改 @Autowired 注入提示

把Autowing for Bean Class 从 Error 改成 Warning

相关文章: