cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Lundquist ...@wrinkledog.com>
Subject Re: [WOODY] - How to bind a repeater from other widget (or add filled in repeaters from another source )
Date Thu, 01 Apr 2004 00:56:18 GMT

On Mar 31, 2004, at 3:03 PM, Joerg Heinicke wrote:

> I think you only need a dynamic selection list.
>
> http://wiki.cocoondev.org/Wiki.jsp?page=WoodyDatatypeReference
>
> <wd:selection-list src="cocoon:/mychoices.xml" dynamic="true"/>

It looks to me like that's not what JD wants to do (changing the 
selection-list items); rather, he wants to have the user pull down the 
menu, and when she lets go, a new row is added based on some 
information from the select control.

I would do that in the flowscript, something like this:

	var wid = form.getWidget();
	.
	.
	wid.thingTypeSelect.onChange =
		function () {
			model.addSelection (wid.thingTypeSelect.value);   // whatever that 
has to do...
			form.load(model);	// re-bind
		}

I should mention that you need to be using the v2 Woody API in order to 
do it this way...

~mark


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message