I have some headaches lately with partial refreshes.
the combobox fires a partial refresh to a panel ( for rendering a field from that panel ), on the onChange event:
<xp:comboBox value="#{Contr.txt_tipcontractcv}" id="txt_tipcontractcv1">
<xp:selectItems id="selectItems1">
<xp:this.value><![CDATA[#{javascript:return ""}]]></xp:this.value>
/xp:selectItems>
<xp:selectItems id="selectItems2">
<xp:this.value><![CDATA[#{javascript:@DbColumn(@DbName(),"SetupvwTipuriContracteC",1);}]]></xp:this.value>
</xp:selectItems>
<xp:eventHandler event="onchange" submit="true">
<xp:this.script><![CDATA[XSP.partialRefreshGet("#{id:FisaP}", {
});
]]> </xp:this.script>
</xp:eventHandler>
</xp:comboBox>
And the code for the panel & the field:
<xp:panel id="FisaP">
<xp:label id="label4">
<xp:this.value><![CDATA[#{javascript:"Fisa contract "+ Contr.getItemValueString("txt_tipcontractcv1")}]]></xp:this.value>
<xp:this.rendered><![CDATA[#{javascript:
Contr.getItemValueString("txt_tipcontractcv1") == "Vanzare-Cumparare"
}]]></xp:this.rendered>
</xp:label>
</xp:panel>
But, when I select a value, the partial refreshes seems to be fired, but immediately the combobox value is null - and a total refresh for the xpage is taken place, and the field from the panel isn't shown. What am I missing?