Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4676

ConversionErrorInterceptor to extend MethodFilterInterceptor

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.5.2
    • 2.5.5
    • Core Interceptors
    • None

    Description

      Would it be possible to modify the ConversionErrorInterceptor to extend MethodFilterInterceptor so I can exclude the validation on certain methods?
      ie

      <interceptor-ref name="conversionError">
          <param name="excludeMethods">execute,cancel*</param>
      </interceptor-ref>
      

      It seems always to be called (needs to be like the validator/workflow)

      I have noticed that if I there is a conversion error on a screen and I return with a redirectAction (and the action has a STORE and the destination action has a RETRIEVE) the conversion error shows on the destination action screen.

      Although I still get in dev mode:

      Error setting expression 'bean.weight' with value ['gggg', ]
      

      as this comes from the params interceptor (and I do not want to exclude this on my cancel), I guess we will have to live with this.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ghuber Greg Huber
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: