inputText reRender fails on Partial page update
jfrankman Jul 10, 2008 12:30 AMI am trying to develop and page where a value is typed into field A, and on the blur event a service is called that updates field B via partial page update. I can get the blur event to trigger the correct method, and when I update a bean value the change is reflected in an outputText component, but if I use an inputText component the value is never updated. Here is my component that triggers the partial page update:
<s:decorate id="zipDecoration" template="layout/editm.xhtml">
<ui:define name="label"> ajax zip2</ui:define>
<h:inputText size="9" maxlength="9" id="zip"
value="#{rptphdmgbinderHome.instance.vehicleVin}"
valueChangeListener="#{rptphdmgbinderHome.verifyVIN}">
<a:support id="vinCheck" bypassUpdates="true" event="onblur"
reRender="binderRemarksDecoration"
ajaxSingle="true" />
</h:inputText>
</s:decorate>
Here is the method on my bean that gets called on the onblur event:
public void verifyVIN(ValueChangeEvent e)
{
EditableValueHolder binderRemarks =(EditableValueHolder) e.getComponent().findComponent(":rptphdmgbinder:binderRemarksDecoration:binderRemarks");
binderRemarks.setValue("zzz");
getInstance().setBinderRemarks("zzz");
}Now, the method above is called, but the binderRemarks field on my form is not updated to 'zzz'. Similar experiements showed that if I used an outputText component instead of an inputText component the outputText component would be updated properly.
Here is the inputText I am trying to have updated:
<s:decorate id="binderRemarksDecoration"
template="layout/edit.xhtml">
<ui:define name="label">Binder Remarks</ui:define>
<h:inputText id="binderRemarks"
value="#{rptphdmgbinderHome.instance.binderRemarks}" />
</s:decorate>Can someone please give me an explanation as to why an inputText field will not get updated on a partial page update but an outputText component will?