ICEfaces
  1. ICEfaces
  2. ICE-11539

ice:selectManyCheckbox labels not working with partialSubmit and blockUIOnSubmit enabled

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: EE-3.3.0.GA_P09
    • Fix Version/s: EE-3.3.0.GA_P10
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      Any
    • Support Case References:
    • Workaround Exists:
      Yes
    • Workaround Description:
      Use h:selectManyCheckbox with f:ajax instead of ice:selectManyCheckbox with partialSubmit or use ace:submitMonitor instead of the blockUIOnSubmit context parameter.

      Description

      Clicking on ice:selectManyCheckbox labels doesn't check/uncheck their corresponding checkboxes when the component has partialSubmit="true" and the application is configured with blockUIOnSubmit set to true as well.

      It seems to be an issue exclusively with ice:selectManyCheckbox. Using ice:selectBooleanCheckbox with ice:outputLabel seems to work fine. Also, using h:selectManyCheckbox with <f:ajax /> works fine too.

      This issue was reproduced with the latest patch sent to the customer and also with the latest patch release P09.

        Activity

        Arturo Zambrano created issue -
        Arturo Zambrano made changes -
        Field Original Value New Value
        Assignee Arturo Zambrano [ artzambrano ]
        Arturo Zambrano made changes -
        Fix Version/s EE-3.3.0.GA_P10 [ 13877 ]
        Arturo Zambrano made changes -
        Workaround Description Use h:selectManyCheckbox with f:ajax instead of ice:selectManyCheckbox with partialSubmit or use ace:submitMonitor instead of the blockUIOnSubmit context parameter.
        Workaround Exists Yes [ 10007 ]
        Hide
        Arturo Zambrano added a comment -

        Committed fix to prevent the partial submit request from being made if the click event comes from the label element of the checkbox, so that only the checkbox's click event gets processed, and thus avoid a double request.

        The issue was that two requests were being made when the label was clicked. This is because the click event is only defined on the root element. So, click events in child elements bubble up until the root element is reached and the partial submit is initiated. Because a click on a label element simulates a click on the input element the label is for, two click events where being triggered. The first one was triggered by the label, which has no client ID and before the checkbox was actually checked. So, no value was actually being submitted with that request and the second request was blocked by the blockUIOnSubmit functionality. This fix prevents the first request triggered by the label, so that only the request triggered by the checkbox itself is sent to the server.

        Show
        Arturo Zambrano added a comment - Committed fix to prevent the partial submit request from being made if the click event comes from the label element of the checkbox, so that only the checkbox's click event gets processed, and thus avoid a double request. The issue was that two requests were being made when the label was clicked. This is because the click event is only defined on the root element. So, click events in child elements bubble up until the root element is reached and the partial submit is initiated. Because a click on a label element simulates a click on the input element the label is for, two click events where being triggered. The first one was triggered by the label, which has no client ID and before the checkbox was actually checked. So, no value was actually being submitted with that request and the second request was blocked by the blockUIOnSubmit functionality. This fix prevents the first request triggered by the label, so that only the request triggered by the checkbox itself is sent to the server.
        Arturo Zambrano made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Arturo Zambrano
            Reporter:
            Arturo Zambrano
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: