2011-09-23 199 views
1

當我通過表單調用一個動作時,我得到以下錯誤。Struts2表單提交錯誤

No result defined for action com.______.actions.UserAction and result input 
     at com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:375) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:277) 
     at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263) 
     at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:68) 
     at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:133) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:207) 
     at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(ParametersInterceptor.java:207) 
     at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:190) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at org.apache.struts2.interceptor.MultiselectInterceptor.intercept(MultiselectInterceptor.java:75) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:94) 
     at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248) 
     at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:243) 

我收到此錯誤invocation.invoke()

如果我打通過URL它工作正常的動作。

請幫助...

以下是有關struts.xml中的片段:

<action name="*Link" method="{1}" class="com.______.actions.UserAction"> 
    <interceptor-ref name="loggingStack"></interceptor-ref> 
    <result name="userInfo" type="tiles">userInfo</result> 
    <result name="sessionout" type="tiles">sessionOut</result> 
</action> 

如果我刪除<interceptor-ref name="loggingStack"></interceptor-ref>它的工作的罰款。

+1

什麼的'loggingStack'是什麼樣子?看起來好像有轉換或驗證錯誤,並且它正在嘗試轉到默認結果「輸入」。 –

+0

'loggingStack'的定義是什麼? – leonbloy

+0

loggingStack是攔截器 – Lohit

回答

1

以上問題已解決?

在我的動作類中,我使用ArrayList<Integer>作爲我的表單提交String。

我改變ArrayList<Integer>to ArrayList<String>