JaceyRx / Examination_System

一个简单的教务查询系统(主要技术SpringMVC + Spring + Mybatis + Shiro + Bootstrap)
1.4k stars 526 forks source link

关于项目学习 #2

Closed mccken closed 4 years ago

mccken commented 7 years ago

你好,我最近在学习你这个项目,仿照你的项目做系统。现在有一些不懂的问题,希望能够获得你的联系方式

nickalc commented 7 years ago

@mccken 请问你的能启动起来吗

JaceyRx commented 7 years ago

@nickalc 你的不能运行起来吗? @mccken 他的可以运行起来

jxnu-liguobin commented 7 years ago

我只想说项目是各种错误

JaceyRx commented 7 years ago

@jxnu-liguobin 能明确一点吗?是项目跑不起来,还是项目代码逻辑不通什么的

Hitaylor commented 7 years ago

我用netbeans编译的,但是报错如下: 严重: Exception while loading the app 严重: Undeployment failed for context /Examination_system/ 严重: Exception while loading the app : java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: org.springframework.beans.factory.BeanDefinitionStoreException: Could not resolve bean definition resource pattern [/WEB-INF/classes/spring/applicationContext-*.xml]; nested exception is java.io.FileNotFoundException: ServletContext resource [/WEB-INF/classes/spring/] cannot be resolved to URL because it does not exist 能否提供更完整的文档呀?谢谢

JaceyRx commented 7 years ago

@Hitaylor 你有没有用Maven编译一遍项目?你的这个错误是 target/classes/ 目录下,找不到 [/WEB-INF/classes/spring/applicationContext-*.xml] 文件,也就是Spring的配置文件,觉得可能是你编译有时的问题..............

Hitaylor commented 7 years ago

我在idea和netbeans中都采用maven编译了,也用了“根据依赖关系编译”,都没有成功。我对Spring不熟悉,看文档里没有说指定配置文件之类的,我看resource目录下有几个配置文件,不知道怎么配置。谢谢。

Hitaylor commented 7 years ago

我使用maven进行了clean和compile,得到target目录以及examination_system.war,然后我选择target中的Examination_System中的login.jsp运行。仍然无法执行。我又将war文件放到tomcat的webapps目录中,仍然无法运行啊。

leitiannian commented 7 years ago

用eclipse无法运行啊, 404错误。 能不能加个qq给解决一下 谢谢 386502782

OneIT-Dog commented 7 years ago

您好!最近在学习您的项目,请问有问题能加QQ详细咨询吗?我的QQ是416497502 谢谢了!

ungenius commented 7 years ago

@Hitaylor @JaceyRx 哈哈我也出现那样的问题了,然后在网上找了两个小时,慢慢解决了,这个项目部的pom.xml中没有将resources目录编译进去,你打开你现在导入项目的web.xml会发现有两处错误,其中一个可以在pom.xml中加上这个

${basedir}/src/main/resources

但是我的web.xml中spring容器还是报错,就将它改成了classpath:spring/applicationContext-*.xml这个。 然后运行项目就可以了...... 哈哈还有一个小坑,就是在配置tomcat的时候,使application context保持"/"就可以,不要自己加目录名

ungenius commented 7 years ago

`

${basedir}/src/main/resources
  </resource>`
amoxuk commented 7 years ago

pom.xml里面加上 ${basedir}/src/main/resources 启动tomcat就可以了

vrmight commented 7 years ago

我用eclipse导入时一直报web.xml is missing and is set to true 但是这个文件有的啊,有人遇到这个问题么?

vrmight commented 7 years ago

有没有大佬用eclipse导入成功并且成功运行的? 求帮我弄一下..

CustomFN commented 7 years ago

@JaceyRx 项目运行成功了,但是登录的时候又报错了,请问是为什么? Type Status Report

Message /login

Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

ttxs0109 commented 7 years ago

你好,项目运行起来,静态资源怎么全是404你们有吗?

aimerwhy commented 6 years ago

@JaceyRx 你好 登录后报404错误,请问是什么原因啊?

Timeriovo commented 6 years ago

@yiyuan0109 我跟你一样,很麻烦。你弄好了吗

Timeriovo commented 6 years ago

我的项目也是各种错

Zeng1998 commented 6 years ago

1 2 想请问为什么会这样,跑不起来??

Zeng1998 commented 6 years ago

org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'collegeServiceImpl': Unsatisfied dependency expressed through field 'collegeMapper'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.system.mapper.CollegeMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)} 能帮忙解答一下吗???

leitiannian commented 6 years ago

你这是bean没注入到Spring容器里吧

发自我的 iPhone

在 2018年2月6日,13:31,Zeng1998 notifications@github.com 写道:

org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'collegeServiceImpl': Unsatisfied dependency expressed through field 'collegeMapper'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.system.mapper.CollegeMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)} 能帮忙解答一下吗???

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

dulestar commented 6 years ago

@JaceyRx 你好,类拷贝BeanUtils这个方法有些使用的是spring的,有些使用的是apache的,两个参数左右赋值顺序不一样,为什么不统一一下,避免混淆。

Junyerw commented 6 years ago

你好,请问可以和你可以交流一下吗,QQ3130482720,谢谢