ICEfaces
  1. ICEfaces
  2. ICE-8276

Regression: The captureSubmit script is still added to forms where f:ajax has been disabled

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.0.BETA2
    • Fix Version/s: 3.1.0.RC1, 3.1
    • Component/s: Bridge, Framework
    • Labels:
      None
    • Environment:
      ICEfaces Core
    • Assignee Priority:
      P2

      Description

      As per ICE-6717, when disabling Ajax for a form:

          <f:ajax disabled="true">
              <h:form id="disabledForm">
                  <h:panelGrid columns="2">
                     ...

      the intent was to prevent the captureSubmit script that we automatically add to forms from being rendered and thus reverting to "stock" form submission (i.e. non-Ajax requests). What I am seeing is that the script is still being rendered but that the form also includes a list of disabled elements which indicates that the bridge should do a "normal" form submission rather than use our form submission code. So the current output looks something like this:

      <form action="/fajax/disabledForm.jsf" enctype="application/x-www-form-urlencoded" id="disabledForm" method="post" name="disabledForm">
      ....
          <script id="disabledForm:disabledForm_captureSubmit" type="text/javascript">ice.captureSubmit('disabledForm',false);ice.captureEnterKey('disabledForm');</script>
      ....
          <input disabled="true" id="disabledForm:ajaxDisabled" type="hidden" value=" disabledForm:cbaDisabledForm disabledForm:cblDisabledForm ">
      ....
      </form>


      The difference is subtle. What we want is for our script not to be rendered so that submits are done in a typical, non-Ajax fashion. What is happening is that our script is being rendered but includes a list of disabled components which indicate the components that should not trigger an Ajax request. The trick is that the final behaviour may look identical (a non-Ajax form submission).

      So it's possible that this may not actually be a regression. Instead, the issue may not have been detected in testing because we simply saw the non-Ajax request and weren't actively checking for the script being rendered.

        Activity

        Repository Revision Date User Message
        ICEsoft Public SVN Repository #29720 Wed Jun 27 12:19:54 MDT 2012 ted.goddard f:ajax wrapping form disabling requires click event to be specified (ICE-8276)
        Files Changed
        Commit graph MODIFY /icefaces3/trunk/icefaces/samples/core/test/fajax/src/main/webapp/disabledCommandButtons.xhtml
        Commit graph MODIFY /icefaces3/trunk/icefaces/samples/core/test/fajax/src/main/webapp/disabledCommandLinks.xhtml

          People

          • Assignee:
            Ted Goddard
            Reporter:
            Deryk Sinotte
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: