ICEfaces
  1. ICEfaces
  2. ICE-10706

ace:fileEntry - Dynamic inclusion causing page refresh

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: EE-4.0.0.GA, EE-3.3.0.GA_P03
    • Fix Version/s: 4.1, EE-3.3.0.GA_P04
    • Component/s: ACE-Components
    • Labels:
      None
    • Environment:
      All
    • Assignee Priority:
      P1
    • Support Case References:
    • Workaround Exists:
      Yes
    • Workaround Description:
      Hide
       - Add an f:ajax tag to the commandButton.
       - Have the fileEntry component rendered initially.
       - Move the fileEntry include to its own form tag.
      Show
       - Add an f:ajax tag to the commandButton.  - Have the fileEntry component rendered initially.  - Move the fileEntry include to its own form tag.

      Description

      When dynamically including content that has an ace:fileEntry on a page and the user clicks a standard h:commandButton, a full page refresh/update is seen.

      This happens only if the fileEntry component is not on the page on the initial load but dynamically added. It also only happens for a button that doesn't use an f:ajax tag (<h:commandButton action="#{fileEntry.doNothing}" value="Do nothing" />). If the fileEntry component is removed from the page, the refresh behavior remains.

        Activity

        Hide
        Arran Mccullough added a comment -

        Attached test case that shows this issue.

        Steps:

        • Load welcomeICEfaces.jsf
        • Click on the first 'Do Nothing' button, no full page refresh is seen.
        • Click on the 'Toggle Included' button to show the fileEntry component.
        • Click on the first 'Do Nothing' button, a full page refresh is seen.
        Show
        Arran Mccullough added a comment - Attached test case that shows this issue. Steps: Load welcomeICEfaces.jsf Click on the first 'Do Nothing' button, no full page refresh is seen. Click on the 'Toggle Included' button to show the fileEntry component. Click on the first 'Do Nothing' button, a full page refresh is seen.
        Hide
        Arran Mccullough added a comment -

        Reported issue is resolved by adding the following context param:

        <context-param>
        <param-name>org.icefaces.mandatoryResourceConfiguration</param-name>
        <param-value>fileEntry</param-value>
        </context-param>

        Show
        Arran Mccullough added a comment - Reported issue is resolved by adding the following context param: <context-param> <param-name>org.icefaces.mandatoryResourceConfiguration</param-name> <param-value>fileEntry</param-value> </context-param>
        Hide
        Arran Mccullough added a comment -

        Re-opening issue. With fixes from ICE-10710 the issue can still be reproduced.

        Show
        Arran Mccullough added a comment - Re-opening issue. With fixes from ICE-10710 the issue can still be reproduced.
        Hide
        Arran Mccullough added a comment -

        Attached new test case that shows this issue even with the mandatoryResourceConfiguration param set.

        Steps:

        • Load welcomeICEfaces.jsf
        • Click on the 'Toogle included (and render @form)' button. The fileEntry comp is now shown.
        • Click on the first 'Do nothing' Button, no issues seen.
        • Click on the 'Toogle included (and render @form)' button. The fileEntry compo is now hidden.
        • Click on the first 'Do nothing' Button, this time an unload/dispose event is fired and the page is refreshed.
        Show
        Arran Mccullough added a comment - Attached new test case that shows this issue even with the mandatoryResourceConfiguration param set. Steps: Load welcomeICEfaces.jsf Click on the 'Toogle included (and render @form)' button. The fileEntry comp is now shown. Click on the first 'Do nothing' Button, no issues seen. Click on the 'Toogle included (and render @form)' button. The fileEntry compo is now hidden. Click on the first 'Do nothing' Button, this time an unload/dispose event is fired and the page is refreshed.
        Hide
        Mircea Toma added a comment -

        Register temporarily a system event listener that un-marks the form as being AJAX disabled. The next JSF lifecycle the form will be AJAX enabled when the file entry is not enclosed anymore.

        Show
        Mircea Toma added a comment - Register temporarily a system event listener that un-marks the form as being AJAX disabled. The next JSF lifecycle the form will be AJAX enabled when the file entry is not enclosed anymore.
        Hide
        Liana Munroe added a comment -

        Verified ICEfaces 4 trunk, EE-3.3.0 maintenance branch r45745 using attached test case. Tomcat 7, IE 11, FF 34, Chrome 43.

        Show
        Liana Munroe added a comment - Verified ICEfaces 4 trunk, EE-3.3.0 maintenance branch r45745 using attached test case. Tomcat 7, IE 11, FF 34, Chrome 43.
        Hide
        Ken Fyten added a comment -

        Re-opened due to regressions noted in ICE-10760.

        Show
        Ken Fyten added a comment - Re-opened due to regressions noted in ICE-10760.
        Hide
        Mircea Toma added a comment - - edited

        Checked in a fix a few days ago, commit #45809

        Show
        Mircea Toma added a comment - - edited Checked in a fix a few days ago, commit #45809
        Hide
        Liana Munroe added a comment -

        Verified ICEfaces 4 trunk, EE-3.3.0 maintenance branch r45816 using attached test case. Tomcat 7, IE 11, 10, 9, 8, 7, FF 34, Chrome 43. ICE-10760 was verified as well.

        Show
        Liana Munroe added a comment - Verified ICEfaces 4 trunk, EE-3.3.0 maintenance branch r45816 using attached test case. Tomcat 7, IE 11, 10, 9, 8, 7, FF 34, Chrome 43. ICE-10760 was verified as well.

          People

          • Assignee:
            Mircea Toma
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: