老師 我這個是在測試的時候出現的 能幫忙解答一下嘛 感激不盡
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'com.example.demo.dao.AreaDaoTest': Unsatisfied dependency expressed through field 'areaDao'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.example.demo.dao.AreaDao' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
2019-03-05
同學好,需要檢查一下你的dao層配置或者你的mapper里面是否沒指定成是AreaDao的實現類,以及是否加入了@Autowired等注解