« Return to Thread: repeatable 2 tier select1

RE: Re: repeatable 2 tier select1

by Park, Michael :: Rate this Message:

Reply to Author | View in Thread

Alex,

Thanks.  Maybe I'm missing something else then. I swapped out the
following as you recommended. The second select1 list for all nodes
changes to whatever index you are currently at:

nodeset="for $pos in index('repeat') return
instance('genre-select')/genre[@auth =
instance('genres')/info[$pos]/@authority]"

for

nodeset="instance('genre-select')/genre[@auth =
instance('genres')/info[xxforms:index('repeat')]/@authority]"


-Mike

-----Original Message-----
From: avernet@... [mailto:avernet@...] On Behalf Of
Alessandro Vernet
Sent: Wednesday, May 07, 2008 1:23 PM
To: ops-users@...
Subject: [ops-users] Re: repeatable 2 tier select1

Mike,

On Tue, May 6, 2008 at 6:14 AM, Park, Michael <Michael_Park_1@...>
wrote:
>     <xforms:itemset nodeset="for $pos in position() return
> instance('genre-select')/genre[@auth =
> instance('genres')/info[$pos]/@authority]">

This should work, but there might be a problem with the above XPath
expression. The context of the "noteset" expression is the node bound
to the select1. So position() will return 1 in this case, and not the
position in the repeat. In this case, the xxforms:index('repeat-id')
extension function should do the trick.

Alex
--
Orbeon Forms - Web 2.0 Forms, open-source, for the Enterprise
Orbeon's Blog: http://www.orbeon.com/blog/
Personal Blog: http://avernet.blogspot.com/
Twitter - http://twitter.com/avernet


--
You receive this message as a subscriber of the ops-users@... mailing list.
To unsubscribe: mailto:ops-users-unsubscribe@...
For general help: mailto:sympa@...?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws

 « Return to Thread: repeatable 2 tier select1

LightInTheBox - Buy quality products at wholesale price