ICEfaces
  1. ICEfaces
  2. ICE-1908

valueChangeListener for all input components called on first partial or full submit

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 1.6
    • Fix Version/s: 1.6.1
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      any

      Description

      ValueChangeListeners for any input component will be fired after the first partial or full submit regardless of whether or not there is really a changed value for the component.

        Activity

        Philip Breau made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Philip Breau made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Won't Fix [ 2 ]
        Philip Breau made changes -
        Resolution Fixed [ 1 ]
        Status Closed [ 6 ] Reopened [ 4 ]
        Philip Breau made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Fixed [ 1 ]
        Hide
        Philip Breau added a comment -

        behaviour matches stock JSF

        • only inputText components bound to String properties will inadvertently fire the valueChangeListener when changing from a null submitted value (initially) and a blank string submitted value (after first partial or full submit). The workaround is to initialize any String properties to empty Strings.
        Show
        Philip Breau added a comment - behaviour matches stock JSF only inputText components bound to String properties will inadvertently fire the valueChangeListener when changing from a null submitted value (initially) and a blank string submitted value (after first partial or full submit). The workaround is to initialize any String properties to empty Strings.
        Ken Fyten made changes -
        Assignee Priority P2 P1
        Ken Fyten made changes -
        Assignee Priority P2
        Ken Fyten made changes -
        Fix Version/s 1.6.1 [ 10070 ]
        Hide
        Greg Dick added a comment -

        I have created some testcases for this issue, since the user reported using Seam. It turns out that this is the normal behavior for JSF applications.

        I created a page with 3 inputTexts I have an ICEfaces+Seam app, ICEfaces only app, and a non-ICEfaces (pure JSF) app. For all three applications, the first time the form is submitted all three fields submit their "" values, and the valueChangeListener method is called. After that, however, for each subsequent form submission, only the field that actually changes has its valueChangeListener method called.

        Since ICEfaces does exactly what the pure JSF application does, and it's not an onerous burden for the lifetime of the application, I think this is doing exactly what it's supposed to.

        Show
        Greg Dick added a comment - I have created some testcases for this issue, since the user reported using Seam. It turns out that this is the normal behavior for JSF applications. I created a page with 3 inputTexts I have an ICEfaces+Seam app, ICEfaces only app, and a non-ICEfaces (pure JSF) app. For all three applications, the first time the form is submitted all three fields submit their "" values, and the valueChangeListener method is called. After that, however, for each subsequent form submission, only the field that actually changes has its valueChangeListener method called. Since ICEfaces does exactly what the pure JSF application does, and it's not an onerous burden for the lifetime of the application, I think this is doing exactly what it's supposed to.
        Hide
        Philip Breau added a comment -

        A partial workaround is to initialize bean String properties to empty Strings. This doesn't address non-String inputs, which aren't able to be initialized with a meaningful non-null value.

        Show
        Philip Breau added a comment - A partial workaround is to initialize bean String properties to empty Strings. This doesn't address non-String inputs, which aren't able to be initialized with a meaningful non-null value.
        Adnan Durrani made changes -
        Assignee Adnan Durrani [ adnan.durrani ]
        Philip Breau made changes -
        Attachment Test_PartialSubmit.zip [ 10522 ]
        Philip Breau made changes -
        Field Original Value New Value
        Support Case References https://www.icesoft.ca:4443/supportilla/show_bug.cgi?id=4184
        ICEfaces Forum Reference http://www.icefaces.org/JForum/posts/list/5137.page
        Support Customer Ref. #s 738
        Philip Breau created issue -

          People

          • Assignee:
            Adnan Durrani
            Reporter:
            Philip Breau
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: