Struts 2: excluding method from validation from just the defaultStack interceptor

不羁的心 提交于 2019-12-01 06:47:54
Jengerer

I figured it out--the solution looks like this:

<action name="Deposit!*" method="{1}" class="csc309.a4.banking.Deposit">
    <result name="success">/banking/Deposit.jsp</result>
    <interceptor-ref name="secureBanking">
        <param name="workflow.excludeMethods">choose</param>
    </interceptor-ref>
</action>

Interceptor parameters can be restricted to specific interceptors by prepending the interceptor name to the parameter name. In this case, only the workflow interceptor will exclude the choose method; other interceptors will still fire for the choose action method.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!