Controller依赖注入错误

最近项目中使用Autofuc实现依赖注入时出现错误:

None of the constructors found with 'Autofac.Core.Activators.Reflection.DefaultConstructorFinder' on type 'XXXController' can be invoked with the available services and parameters

实现依赖注入的时候要记得Service要继承ApplicationService
posted @ 2018-03-26 10:18  BernardBlack  阅读(419)  评论(0编辑  收藏  举报