springboot easypoi 报错The bean 'beanNameViewResolver', defined in class path resource [cn/afterturn/e

今天在用springboot easypoi 做导出导入时,配置完成后启动项目报The bean ‘beanNameViewResolver’, defined in class path resource [cn/afterturn/easypoi/configuration/EasyPoiAutoConfiguration.class], could not be registered. A bean with that name has already been defined in class path resource [org/springframework/boot/autoconfigure/web/servlet/error/ErrorMvcAutoConfiguration$WhitelabelErrorViewConfiguration.class] and overriding is disabled.
查找了很久,都没有解决问题,最后在一篇博客里,找到了解决方案:在spring配置文件里,加入springboot easypoi 报错The bean 'beanNameViewResolver', defined in class path resource [cn/afterturn/e_第1张图片
项目终于正常启动!!!

你可能感兴趣的:(springboot,poi)