更新项目以后,新增了许多java类,运行application来启动项目时报错:

Parameter 0 of constructor in me.zhengjie.modules.system.rest.DictDetailController required a bean of type 'me.zhengjie.modules.system.service.DictDetailService' that could not be found.

刚开始以为是文件DictDetailService不存在,结果不是,删除再导入后也解决不了问题。最终靠以下步骤解决:

  1. 点击界面左侧的maven管理,再点击root下的生命周期,点击clean(也可以直接控制台运行 mvn clean,一样的效果)
    在这里插入图片描述
  2. 右键根项目(root),点击重新加载项目。等待加载完再运行就没问题了!!!
    在这里插入图片描述
Logo

旨在为数千万中国开发者提供一个无缝且高效的云端环境,以支持学习、使用和贡献开源项目。

更多推荐