首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网络技术 > 网络基础 >

strust2 2.0.4版本中证验返回类型为chain时执行action配置

2012-08-29 
strust2 2.0.4版本中验证返回类型为chain时执行action配置struts2 2.0.4中 修改defaultStack,将chain拦截

strust2 2.0.4版本中验证返回类型为chain时执行action配置

struts2 2.0.4中 修改defaultStack,将chain拦截器放到最后

  <interceptor-ref name="exception"/>                <interceptor-ref name="alias"/>                <interceptor-ref name="servletConfig"/>                <interceptor-ref name="prepare"/>                <interceptor-ref name="i18n"/>                               <interceptor-ref name="debugging"/>                <interceptor-ref name="profiling"/>                <interceptor-ref name="scopedModelDriven"/>                <interceptor-ref name="modelDriven"/>                <interceptor-ref name="fileUpload"/>                <interceptor-ref name="checkbox"/>                <interceptor-ref name="staticParams"/>                <interceptor-ref name="params">                  <param name="excludeParams">dojo\..*</param>                </interceptor-ref>                <interceptor-ref name="conversionError"/>                <interceptor-ref name="validation">                    <param name="excludeMethods">back,cancel,browse</param>                </interceptor-ref>                                              <interceptor-ref name="workflow">                    <param name="excludeMethods">back,cancel,browse</param>                    <!-- 把chain放到最后 -->                </interceptor-ref>                                               <interceptor-ref name="chain"/>
<result name="input" type="chain"><param name="namespace">/</param><param name="actionName">updatePUser</param><param name="method ">abc</param></result>

?则会验证失败时会显示错误消息,同时会显示执行chain - action中的方法

热点排行