|
View:
New views
6 Messages
—
Rating Filter:
Alert me
|
|
|
Dynafaces in a table
I'm trying to use dynamic faces to update components in a table.
The table contains a dropdown list, and I'm trying to update another component on the same row based on the selected value in the dropdown. However it seems the events are not being invoked at all. No JS error messages appear. I'm using NB 6.1 with VWP / Dynafaces Here's the JSP code. The Java class is pretty empty so far - the valueChanged method doesn't get invoked. Can anyone help? Ramon Casha <?xml version="1.0" encoding="UTF-8"?> <jsp:root version="2.1" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:jsfExt="http://java.sun.com/jsf/extensions/dynafaces" xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:webuijsf="http://www.sun.com/webui/webuijsf"> <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/> <f:view> <webuijsf:page id="page1"> <webuijsf:html id="html1"> <webuijsf:head id="head1"> <webuijsf:link id="link1" url="/resources/stylesheet.css"/> </webuijsf:head> <webuijsf:body id="body1" style="-rave-layout: flow"> <webuijsf:form id="form1"> <jsfExt:ajaxZone eventType="onchange" id="zone1"> <webuijsf:table augmentTitle="false" id="table1" title="Temp"> <webuijsf:tableRowGroup binding="#{Page1.tableRowGroup1}" id="tableRowGroup1" rows="10" sourceData="#{SessionBean1.testds}" sourceVar="currentRow"> <webuijsf:tableColumn headerText="locale" id="tableColumn1"> <webuijsf:dropDown binding="#{Page1.fldLocale}" converter="#{Page1.fldLocaleConverter}" id="fldLocale" items="#{ApplicationBean1.locales}" selected="#{currentRow.value['locale']}" valueChangeListenerExpression="#{Page1.onLocaleChange}"/> </webuijsf:tableColumn> <webuijsf:tableColumn headerText="name" id="tableColumn2" sort="name"> <webuijsf:textField id="textField1" text="#{currentRow.value['name']}"/> </webuijsf:tableColumn> <webuijsf:tableColumn headerText="description" id="tableColumn3" sort="description"> <webuijsf:textField id="textField2" text="#{currentRow.value['description']}"/> </webuijsf:tableColumn> <webuijsf:tableColumn headerText="country" id="tableColumn4" sort="country"> <webuijsf:textField binding="#{Page1.fldCountry}" id="fldCountry" text="#{currentRow.value['country']}"/> </webuijsf:tableColumn> <webuijsf:tableColumn headerText="ISO3" id="tableColumn5" sort="ISO3"> <webuijsf:staticText id="fldISO" text="#{currentRow.value['ISO3']}"/> </webuijsf:tableColumn> </webuijsf:tableRowGroup> </webuijsf:table> </jsfExt:ajaxZone> <webuijsf:button actionExpression="#{Page1.button1_action}" id="button1" text="Button"/> </webuijsf:form> </webuijsf:body> </webuijsf:html> </webuijsf:page> </f:view> </jsp:root>
DISCLAIMER The information contained in this electronic mail may be confidential or legally privileged. It is for the intended recipient(s) only. Should you receive this message in error, please notify the sender by replying to this mail. Unauthorised use of the contents is strictly prohibited. Whilst all care has been taken, the Megabyte Group is not responsible for the integrity of the contents of this electronic mail and any attachments included within.
|
|
|
Re: Dynafaces in a tableI've never got those zones working.
Try using DynaFaces.fireAjaxTransaction(). I've been more lucky with that.
|
|
|
Re: Dynafaces in a tableUnfortunately I haven't been too successful with ajaxTransactions
either. The first time I select a value in the dropdown it works perfectly, but the second time it won't. In the Firefox error console I get the following error with the second selection: Error: [Exception... "Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXMLHttpRequest.open]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: http://localhost:8080/Timesheets/faces/static/META-INF/libs/scriptaculous/version1.6.4/prototype.js :: anonymous :: line 1" data: no] Source File: http://localhost:8080/Timesheets/faces/static/META-INF/libs/scriptaculous/version1.6.4/prototype.js Line: 1 I also got the impression that it's re-rendering the entire page, not jusy the table. In fact when I tried using sitemesh, the JSF page is rerendered over the sitemesh template. However the above error is generated even with sitemesh disabled. Ramon Casha On Fri, 2008-07-18 at 02:33 -0700, Stefan Bley wrote: > I've never got those zones working. > Try using DynaFaces.fireAjaxTransaction(). I've been more lucky with that. > > > Ramon Casha wrote: > > > > I'm trying to use dynamic faces to update components in a table. > > > > The table contains a dropdown list, and I'm trying to update another > > component on the same row based on the selected value in the dropdown. > > However it seems the events are not being invoked at all. No JS error > > messages appear. > > > > Can anyone help? > > > > Ramon Casha > > > DISCLAIMER ---------------------- The information contained in this electronic mail may be confidential or legally privileged. It is for the intended recipient(s) only. Should you receive this message in error, please notify the sender by replying to this mail. Unauthorised use of the contents is strictly prohibited. Whilst all care has been taken, the Megabyte Group is not responsible for the integrity of the contents of this electronic mail and any attachments included within. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@... For additional commands, e-mail: users-help@... |
|
|
Re: Dynafaces in a tableDon't forget to include
<jsfExt:scripts/> in your page head. Could be a cause for your js error message. Stevy
|
|
|
Re: Dynafaces in a tableNo, that's not it. If it was, it would give that error immediately, not
on the second ajax transaction. Ramon Casha On Fri, 2008-07-18 at 03:43 -0700, Stefan Bley wrote: > Don't forget to include > <jsfExt:scripts/> > in your page head. Could be a cause for your js error message. > > Stevy > > > Ramon Casha wrote: > > > > Error: [Exception... "Component returned failure code: 0x80070057 > > (NS_ERROR_ILLEGAL_VALUE) [nsIXMLHttpRequest.open]" nsresult: > > "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame :: > > http://localhost:8080/Timesheets/faces/static/META-INF/libs/scriptaculous/version1.6.4/prototype.js > > :: anonymous :: line 1" data: no] > > Source File: > > http://localhost:8080/Timesheets/faces/static/META-INF/libs/scriptaculous/version1.6.4/prototype.js > > Line: 1 > > > DISCLAIMER ---------------------- The information contained in this electronic mail may be confidential or legally privileged. It is for the intended recipient(s) only. Should you receive this message in error, please notify the sender by replying to this mail. Unauthorised use of the contents is strictly prohibited. Whilst all care has been taken, the Megabyte Group is not responsible for the integrity of the contents of this electronic mail and any attachments included within. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@... For additional commands, e-mail: users-help@... |
|
|
Re: Dynafaces in a tableI never got Woodstock components working fine with Dynafaces. I'll wait JSF 2.0 to ajaxify my applications.
2008/7/18 Ramon Casha <ramon.casha@...>: No, that's not it. If it was, it would give that error immediately, not |
| Free Forum Powered by Nabble | Forum Help |