ICEfaces
  1. ICEfaces
  2. ICE-8438

Input values cleared out when SingleSubmit or PartialSubmit enabled

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 3.1
    • Fix Version/s: None
    • Component/s: Release
    • Labels:
      None
    • Environment:
      Windows 7, MyEclipse10.5,Java 1.6

      Description

      I have <icecore:singleSubmit/> as the first statement under the <ice:form id="personalInfoPageForm">
      Whenever I enter any value in the input fields and tab out to the next one the input value in the first column is cleared out.
      The above FireBug net log shows what's happening:

      [code]
      Parametersapplication/x-www-form-urlencoded
      ice.event.alt false
      ice.event.captured personalInfoPageForm:vehInfoNextBtn
      ice.event.ctrl false
      ice.event.left true
      ice.event.meta false
      ice.event.right false
      ice.event.shift false
      ice.event.target personalInfoPageForm:vehInfoNextBtn
      ice.event.type onclick
      ice.event.x 742
      ice.event.y 848
      ice.focus personalInfoPageForm:vehInfoNextBtn
      ice.submit.serialization form
      ice.submit.type ice.s
      ice.view vj4xoy22
      ice.view vj4xoy22
      ice.window 5eh5ealwmx
      ice.window 5eh5ealwmx
      icefacesCssUpdates
      j_idt42:j_idt142 on
      javax.faces.ViewState -4646881556413888458:8412178051094007253
      javax.faces.partial.ajax true
      javax.faces.partial.event click
      javax.faces.partial.execu... @all
      javax.faces.partial.rende... @all
      javax.faces.source personalInfoPageForm:vehInfoNextBtn
      personalInfoPageForm personalInfoPageForm
      personalInfoPageForm:date... 01/01/1968
      personalInfoPageForm:emai... bnair@test.com
      personalInfoPageForm:esAg... 0
      personalInfoPageForm:firs... Test5
      personalInfoPageForm:j_id...
      personalInfoPageForm:j_id...
      personalInfoPageForm:last... TestLast6
      personalInfoPageForm:mail...
      personalInfoPageForm:mail...
      personalInfoPageForm:mail... Houston
      personalInfoPageForm:mail... TX
      personalInfoPageForm:mail... 77041
      personalInfoPageForm:midd...
      personalInfoPageForm:poli... 08/03/2012
      personalInfoPageForm:poli...
      personalInfoPageForm:prim... (254) 125-6988
      personalInfoPageForm:vehI...
      Source
      personalInfoPageForm=personalInfoPageForm&javax.faces.ViewState=-4646881556413888458%3A8412178051094007253&ice.window=5eh5ealwmx&ice.view=vj4xoy22&personalInfoPageForm%3AesAgentAccountId=0&personalInfoPageForm%3AfirstName=Test5&personalInfoPageForm%3AmiddleName=&personalInfoPageForm%3AlastName=TestLast6&personalInfoPageForm%3AdateOfBirth=01%2F01%2F1968&personalInfoPageForm%3Aemail=bnair%40test.com&personalInfoPageForm%3AprimaryPhone=(254)%20125-6988&personalInfoPageForm%3AmailingAddress1=&personalInfoPageForm%3AmailingAddress2=&personalInfoPageForm%3AmailingCity=Houston&personalInfoPageForm%3AmailingState=TX&personalInfoPageForm%3AmailingZipCode=77041&j_idt42%3Aj_idt142=on&personalInfoPageForm%3ApolicyEffectiveDate=08%2F03%2F2012&icefacesCssUpdates=&personalInfoPageForm%3ApolicyEffectiveDate_cc=&personalInfoPageForm%3Aj_idpersonalInfoPageForm%3ApolicyEffectiveDatesp=&personalInfoPageForm%3Aj_idcl=&javax.faces.source=personalInfoPageForm%3AvehInfoNextBtn&javax.faces.partial.event=click&javax.faces.partial.execute=%40all&javax.faces.partial.render=%40all&ice.window=5eh5ealwmx&ice.view=vj4xoy22&ice.focus=personalInfoPageForm%3AvehInfoNextBtn&personalInfoPageForm%3AvehInfoNextBtn=&ice.event.target=personalInfoPageForm%3AvehInfoNextBtn&ice.event.captured=personalInfoPageForm%3AvehInfoNextBtn&ice.event.type=onclick&ice.event.alt=false&ice.event.ctrl=false&ice.event.shift=false&ice.event.meta=false&ice.event.x=742&ice.event.y=848&ice.event.left=true&ice.event.right=false&ice.submit.type=ice.s&ice.submit.serialization=form&javax.faces.partial.ajax=true
      [/code]
      And the response comes back as:
      [code]
      <partial-response>
      <changes>
      <update id="personalInfoPageForm:esAgentAccountId"><select class="iceSelOneMnu selectFieldControl" id="personalInfoPageForm:esAgentAccountId" name="personalInfoPageForm:esAgentAccountId" onblur="setFocus('');" onfocus="setFocus(this.id);" size="1" tabindex="0"><option selected="selected" value=""></option><option value="0">Not Registered</option></select></update>
      <update id="personalInfoPageForm:firstName"><input class="iceInpTxt stdFieldControl" id="personalInfoPageForm:firstName" name="personalInfoPageForm:firstName" onblur="setFocus('');" onfocus="setFocus(this.id);" onkeyup="iceSubmit(form,this,event);" onmousedown="this.focus();" tabindex="1" type="text" value="" /></update>
      <update id="personalInfoPageForm:lastName"><input class="iceInpTxt stdFieldControl" id="personalInfoPageForm:lastName" name="personalInfoPageForm:lastName" onblur="setFocus('');" onfocus="setFocus(this.id);" onkeyup="iceSubmit(form,this,event);" onmousedown="this.focus();" tabindex="3" type="text" value="" /></update>
      <update id="personalInfoPageForm:dateOfBirth"><input class="ui-inputfield ui-inputmask ui-widget ui-state-default ui-corner-all dateFieldControl" id="personalInfoPageForm:dateOfBirth" name="personalInfoPageForm:dateOfBirth" tabindex="4" type="text" /></update>
      <update id="personalInfoPageForm:email"><input class="iceInpTxt stdFieldControl" id="personalInfoPageForm:email" name="personalInfoPageForm:email" onblur="setFocus('');" onfocus="setFocus(this.id);" onkeyup="iceSubmit(form,this,event);" onmousedown="this.focus();" tabindex="5" type="text" value="" /></update>
      <update id="personalInfoPageForm:primaryPhone"><input class="ui-inputfield ui-inputmask ui-widget ui-state-default ui-corner-all stdFieldControl" id="personalInfoPageForm:primaryPhone" name="personalInfoPageForm:primaryPhone" tabindex="6" type="text" /></update>
      <update id="personalInfoPageForm:mailingCity"><input class="iceInpTxt stdFieldControl" id="personalInfoPageForm:mailingCity" name="personalInfoPageForm:mailingCity" onblur="setFocus('');" onfocus="setFocus(this.id);" onkeyup="iceSubmit(form,this,event);" onmousedown="this.focus();" tabindex="12" type="text" value="" /></update>
      <update id="personalInfoPageForm:mailingState"><select class="stateFieldControl" id="personalInfoPageForm:mailingState" name="personalInfoPageForm:mailingState" size="1" tabindex="13"> <option value=""></option> <option value="AL">Alabama</option> <option value="AK">Alaska</option> <option value="AZ">Arizona</option> <option value="AR">Arkansas</option> <option value="CA">California</option> <option value="CO">Colorado</option> <option value="CT">Connecticut</option> <option value="DE">Delaware</option> <option value="DC">District of Columbia</option> <option value="FL">Florida</option> <option value="GA">Georgia</option> <option value="HI">Hawaii</option> <option value="ID">Idaho</option> <option value="IL">Illinois</option> <option value="IN">Indiania</option> <option value="IA">Iowa</option> <option value="KS">Kansas</option> <option value="KY">Kentucky</option> <option value="LA">Louisiana</option> <option value="ME">Maine</option> <option value="MD">Maryland</option> <option value="MA">Massachusetts</option> <option value="MI">Michigan</option> <option value="MN">Minnesota</option> <option value="MS">Mississippi</option> <option value="MO">Missouri</option> <option value="MT">Montana</option> <option value="NE">Nebraska</option> <option value="NV">Nevada</option> <option value="NH">New Hampshire</option> <option value="NJ">New Jersey</option> <option value="NY">New York</option> <option value="NM">NewMexico</option> <option value="NC">North Carolina</option> <option value="ND">North Dakota</option> <option value="OH">Ohio</option> <option value="OK">Oklahoma</option> <option value="OR">Oregon</option> <option value="PA">Pennsylvania</option> <option value="RI">Rhode Island</option> <option value="SC">South Carolina</option> <option value="SD">South Dakota</option> <option value="TN">Tennessee</option> <option value="TX">Texas</option> <option value="UT">Utah</option> <option value="VT">Vermont</option> <option value="VA">Virginia</option> <option value="WA">Washington</option> <option value="WV">West Virginia</option> <option value="WI">Wisconsin</option> <option value="WY">Wyoming</option> </select></update>
      <update id="personalInfoPageForm:mailingZipCode"><input class="ui-inputfield ui-inputmask ui-widget ui-state-default ui-corner-all zipFieldControl" id="personalInfoPageForm:mailingZipCode" name="personalInfoPageForm:mailingZipCode" size="5" tabindex="14" type="text" /></update>
      <update id="personalInfoPageForm:vehInfoNextBtn"><input class="iceCmdBtn" id="personalInfoPageForm:vehInfoNextBtn" name="personalInfoPageForm:vehInfoNextBtn" src="/images/en_US-button-next.png" tabindex="50" type="image" /></update>
      <update id="javax.faces.ViewState">-4646881556413888458:8412178051094007253</update>
      <eval>ice.applyFocus('personalInfoPageForm:vehInfoNextBtn');</eval>
      <eval>new Ice.MenuBarKeyNavigator('j_idt11:j_idt13', false, false, true);new Ice.MenuBarKeyNavigator('j_idt11:j_idt13', false, false, true); Ice.autoPosition.stop('progress'); Ice.autoCentre.start('progress',false); Ice.iFrameFix.start('progress','/xmlhttp/blank');//1493316869</eval>
      <extension aceCallbackParam="validationFailed">{"validationFailed":false}</extension>
      </changes>
      </partial-response>
      [/code]

      Reverting back to the following Icefaces 2.0/JSF 2.x configuration:
      <ice.version>2.0.0</ice.version>
      <jsf.version>2.0.3-FCS</jsf.version>
      makes all the issues go away.

      This clearly shows that this is a non-documented setting/configuration issue that is causing this. I have made sure that all the recommended steps in the migration document and release notes have been implemented.

        Activity

        Hide
        Biju Nair added a comment -

        This issue is primarily attributable to the usage of the c:forEach and c:if usage in the facelets to build dynamic content.
        I am attaching a war file that shows the issue when the values in the applicant form are entered and tab pressed.
        This was working fine with the previous version of IceFaces

        I was able to find a workaround by replacing all the c:forEach and c:if with ice:panelSeries and rendered attributes but the workaround needed the use of another XHTML, a library of hard-coded references to the component facelet fragments as the ui:include does not work with expression directly.
        The war file has all of these files.

        Show
        Biju Nair added a comment - This issue is primarily attributable to the usage of the c:forEach and c:if usage in the facelets to build dynamic content. I am attaching a war file that shows the issue when the values in the applicant form are entered and tab pressed. This was working fine with the previous version of IceFaces I was able to find a workaround by replacing all the c:forEach and c:if with ice:panelSeries and rendered attributes but the workaround needed the use of another XHTML, a library of hard-coded references to the component facelet fragments as the ui:include does not work with expression directly. The war file has all of these files.
        Hide
        Ken Fyten added a comment -

        Mixing icecore:singleSubmit and partialSubmit=true in the same form is not supported. Please confirm this is not the scenario here and also attach a simple test-case to reproduce.

        Show
        Ken Fyten added a comment - Mixing icecore:singleSubmit and partialSubmit=true in the same form is not supported. Please confirm this is not the scenario here and also attach a simple test-case to reproduce.
        Hide
        Biju Nair added a comment -

        Ken:

        No it is not mixed, as in the attached project. I meant to say having one or the other with the mentioned method of creating the dynamic content causes this issue.

        Thanks,
        Biju

        Show
        Biju Nair added a comment - Ken: No it is not mixed, as in the attached project. I meant to say having one or the other with the mentioned method of creating the dynamic content causes this issue. Thanks, Biju
        Hide
        Deryk Sinotte added a comment - - edited

        This is issue has been marked as depending on ICE-8554, a case which looks =
        to improve support for singleSubmit when using compat components.
        The test case attached to this case doesn't work for me. When I deploy the=
        .war file to Tomcat and try to load the page, it fails with the following =
        exception:
        SEVERE: Error Rendering View[/applicantForm.xhtml]
        javax.el.ELException: /applicantForm.xhtml: Property 'pages' not found on t=
        ype training.jobapplication.bean.model.Applicant
        =09at com.sun.faces.facelets.compiler.AttributeInstruction.write(AttributeI=
        nstruction.java:94)
        =09at com.sun.faces.facelets.compiler.UIInstructions.encodeBegin(UIInstruct=
        ions.java:82)
        =09at com.sun.faces.facelets.compiler.UILeaf.encodeAll(UILeaf.java:183)
        =09at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1760)
        =09at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1760)
        =09at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1760)
        =09at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView=
        (FaceletViewHandlingStrategy.java:402)
        =09at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewH=
        andler.java:131)
        =09at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePha=
        se.java:121)
        =09at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
        =09at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
        =09at javax.faces.webapp.FacesServlet.service(FacesServlet.java:594)
        =09at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl=
        icationFilterChain.java:305)
        =09at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF=
        ilterChain.java:210)
        =09at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV=
        alve.java:225)
        =09at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV=
        alve.java:123)
        =09at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica=
        torBase.java:472)
        =09at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j=
        ava:168)
        =09at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j=
        ava:98)
        =09at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:=
        927)
        =09at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal=
        ve.java:118)
        =09at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav=
        a:407)
        =09at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp=
        11Processor.java:1001)
        =09at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(=
        AbstractProtocol.java:585)
        =09at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoin=
        t.java:312)
        =09at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExec=
        utor.java:886)
        =09at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor=
        .java:908)
        =09at java.lang.Thread.run(Thread.java:680)
        If you would like us to test future fixes against your test case, please re=
        submit a functioning example.
        =20

        Show
        Deryk Sinotte added a comment - - edited This is issue has been marked as depending on ICE-8554 , a case which looks = to improve support for singleSubmit when using compat components. The test case attached to this case doesn't work for me. When I deploy the= .war file to Tomcat and try to load the page, it fails with the following = exception: SEVERE: Error Rendering View [/applicantForm.xhtml] javax.el.ELException: /applicantForm.xhtml: Property 'pages' not found on t= ype training.jobapplication.bean.model.Applicant =09at com.sun.faces.facelets.compiler.AttributeInstruction.write(AttributeI= nstruction.java:94) =09at com.sun.faces.facelets.compiler.UIInstructions.encodeBegin(UIInstruct= ions.java:82) =09at com.sun.faces.facelets.compiler.UILeaf.encodeAll(UILeaf.java:183) =09at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1760) =09at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1760) =09at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1760) =09at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView= (FaceletViewHandlingStrategy.java:402) =09at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewH= andler.java:131) =09at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePha= se.java:121) =09at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) =09at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) =09at javax.faces.webapp.FacesServlet.service(FacesServlet.java:594) =09at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl= icationFilterChain.java:305) =09at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF= ilterChain.java:210) =09at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV= alve.java:225) =09at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV= alve.java:123) =09at org.apache.catalina.authenticator.AuthenticatorBase.invoke(Authentica= torBase.java:472) =09at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j= ava:168) =09at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j= ava:98) =09at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:= 927) =09at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal= ve.java:118) =09at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav= a:407) =09at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp= 11Processor.java:1001) =09at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(= AbstractProtocol.java:585) =09at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoin= t.java:312) =09at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExec= utor.java:886) =09at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor= .java:908) =09at java.lang.Thread.run(Thread.java:680) If you would like us to test future fixes against your test case, please re= submit a functioning example. =20
        Hide
        Biju Nair added a comment - - edited

        Deryk:
        Sorry about that. Attached is the fixed WAR file. The resources had not got=
        copied over.

        Thanks,
        Biju
        =20

        Show
        Biju Nair added a comment - - edited Deryk: Sorry about that. Attached is the fixed WAR file. The resources had not got= copied over. Thanks, Biju =20
        Hide
        Biju Nair added a comment - - edited

        Can the title be modified to "Migration to Icefaces 3.1.0 causes input valu=
        es cleared out when SingleSubmit or PartialSubmit is turned on"?
        =20

        Show
        Biju Nair added a comment - - edited Can the title be modified to "Migration to Icefaces 3.1.0 causes input valu= es cleared out when SingleSubmit or PartialSubmit is turned on"? =20
        Hide
        Biju Nair added a comment -

        Any updated on this bug?
        At one point it showed as if this would be fixed by version 3.2, but I do not see it as being fixed.
        The status shows as open and unresolved.
        Can someone please address as to when this could be fixed?

        Thanks,
        Biju

        Show
        Biju Nair added a comment - Any updated on this bug? At one point it showed as if this would be fixed by version 3.2, but I do not see it as being fixed. The status shows as open and unresolved. Can someone please address as to when this could be fixed? Thanks, Biju
        Hide
        Ken Fyten added a comment -

        Can you retest your sample with ICEfaces 3.2?

        It is difficult to prioritize customer application scenario issues without a support contract. We'll see what we can do assuming this is still an issue on 3.2.

        Show
        Ken Fyten added a comment - Can you retest your sample with ICEfaces 3.2? It is difficult to prioritize customer application scenario issues without a support contract. We'll see what we can do assuming this is still an issue on 3.2.

          People

          • Assignee:
            Unassigned
            Reporter:
            Biju Nair
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated: