求大神帮忙解答一下
<action name="ListCustomerAction_*" class="com.yzh.web.action.ListCustomerAction" method="{1}">
<result name="list">/jsp/customer/list.jsp</result>
<result name="toList" type="redirectAction">
<param name="actionName">ListCustomerAction_list</param>
<param name="namespace">/</param>
</result>
</action>
<action name="LinkManAction_*" class="com.yzh.web.action.LinkManAction" method="{1}">
<result name="list">/jsp/linkman/list.jsp</result>
<result name="toList" type="redirectAction">
<param name="actionName">LinkManAction_list</param>
<param name="namespace">/</param>
</result>
</action>
为啥LinkManAction_会报这个错误呀,明明写了这个方法,求大神帮忙解答一下
警告: Could not find action or result: /hibernate_01/LinkManAction_add
No result defined for action com.yzh.web.action.LinkManAction and result error - action - file:/F:/demo/.metadata/.me_tcat7/webapps/hibernate_01/WEB-INF/classes/struts.xml:39:87
at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:371)
at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:273)
at com.yzh.web.interceptor.LoginInterceptor.doIntercept(LoginInterceptor.java:22)
at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)
at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:244)
at org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:54)
at org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:564)
at org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81)
at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1002)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:585)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:744) 我都看不懂 没用过 struts ,老项目吗,现在都用 spring 了,我只听说 struts 的 bug 多,debug + 搜索 慢慢看吧 VioletKiss 发表于 2019-9-26 19:01
没用过 struts ,老项目吗,现在都用 spring 了,我只听说 struts 的 bug 多,debug + 搜索 慢慢看吧
联系一下而已,谢谢了 搞定了,action接收参数字段与jsp传的不一致导致的。
页:
[1]