myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Madhav Bhargava <>
Subject How to get hold of the event queue in JSF?
Date Tue, 30 Dec 2008 10:14:01 GMT
Hi All,

I am using Sun JSF RI 1.1_02, Tomahawk -1.1.6, tomahawk-sandbox-1.1.6, richfaces-3.1.6

I have a page where there is are 2 drop downs:
<t:selectOneMenu id="provTypCd" style="width:163"

                <f:selectItems id="selitms1"
                <a4j:support event="onchange"

<t:selectOneMenu id="rtsMdlkey" style="width:163"

                <f:selectItems id="selitms21"
                <a4j:support event="onchange"

And there are 2 input text boxes: (Note: I am not using required="true" because there is a
problem with Sun JSF RI with the way they handle messages on validation errors)
<t:inputText id="percentageVal" size="23" align="left"
                forceId="true" value="#{durMaintenanceController.lkupPercentage}"
                <f:converter converterId="com.wellpoint.benefitbuilder.NullConverter" />
                <custom:requiredValidator />
                <custom:validateDoubleRange minimum="0" maximum="100" />

<t:inputText id="descrptn" size="23" align="left" maxlength="100"
                forceId="true" value="#{durMaintenanceController.description}">
                                converterId="com.wellpoint.benefitbuilder.NullConverter" />
                <custom:requiredValidator />

Now on change of the second drop down I need to refresh the values in the text boxes but not
validate them. However I only need to validate them when an input button is clicked. Now I
enclosed these text boxes in a <s:subForm> component. After which the validation errors
were gone when the page got submitted using ajax4jsf support but since the subForm component
was not submitted the processModelUpdates was not called for the components within the subForm.
Upon re-render of a4j:support then show the older values.

I guess I will not be able to use s:subForm along with a4j:support. Is there any way I can
get access to eventQueue so that I can check what are the events queued by the end of apply
request phase. Looking at the events I can check in my validators whether to validate the
field or not. That is the only solution that comes to mind right now.

However I am stuck because I do not know how to get hold of the event queue. Can anyone throw
some light?


**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely 
for the use of the addressee(s). If you are not the intended recipient, please 
notify the sender by e-mail and delete the original message. Further, you are not 
to copy, disclose, or distribute this e-mail or its contents to any other person and 
any such actions are unlawful. This e-mail may contain viruses. Infosys has taken 
every reasonable precaution to minimize this risk, but is not liable for any damage 
you may sustain as a result of any virus in this e-mail. You should carry out your 
own virus checks before opening the e-mail or attachment. Infosys reserves the 
right to monitor and review the content of all messages sent to or from this e-mail 
address. Messages sent to or from this e-mail address may be stored on the 
Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***

View raw message