您好,错误提示是您的”htmlServiceImpl“这个bean没有定义,可能您的”userController“的实现需要这个bean,但是您又没有在spring容器中声明它,建议做法:
//1.在类的声明前加上@Repository@Repository
public class htmlServiceImpl{
.......
}
//2.在applicationContext.xml中添加如下一行
<bean id="htmlServiceImpl" class="您的类所在的位置,如com.service.htmlServiceImpl"/>
希望采纳,并且祝您Spring学习之旅愉快!
前端参数传递有问题,这样写后台无法解析 {"dep_id":this.selected} json 试一下:将dep_id放到URL里面 "http://url?dep_id="+this.selected
你貌似没有引入'userController' 这个类的包。。所以spring 不认识它。所以没发注入。<context:component-scan base-package="myforum.dao,myforum.service" />这样的写法。我没用过。我都是把2个包分开写。不知道你的这个'userController' 是不是在 ,myforum.service包下
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)