mulitple repeated items

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

mulitple repeated items

Colin Seaman
Guys,

Has anyone got a good example of a repeat within a repeat within an
xform?  Something like:

<Doc>
<contact>
    <name>
    <address></address>
    <telephone>
       <number></number>
    </telephone>
    <telephone>
       <number></number>
    </telephone>
</contact>
<contact>
    <name>
    <address></address>
    <telephone>
       <number></number>
    </telephone>
    <telephone>
       <number></number>
    </telephone>
</contact>
</Doc>

--
Colin Seaman
Senior Developer
 
Tradocs Ltd,
Tower Point,
44 North Road,
Brighton,
BN1 1YR

email:     [hidden email]
skype:     colin,seaman
telephone: 0870-1417031
website:   http://www.tradocs.net

This email and any files transmitted with it are confidential
and intended solely for the use of the individual or entity to
whom they are addressed. If you have received this email in
error please contact Tradocs. Please note that any views or
opinions presented in this email are solely those of the author
and do not necessarily represent those of the company. Finally,
the recipient should check this email and any attachments for
the presence of viruses. The company accepts no liability for
any damage caused by any virus transmitted by this email.
This content of this email is without prejudice.




--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: mulitple repeated items

Erik Bruchez
Administrator
Colin,

The To-Do Lists example shows something like this.

-Erik

Colin Seaman wrote:

> Guys,
>
> Has anyone got a good example of a repeat within a repeat within an
> xform?  Something like:
>
> <Doc>
> <contact>
>    <name>
>    <address></address>
>    <telephone>
>       <number></number>
>    </telephone>
>    <telephone>
>       <number></number>
>    </telephone>
> </contact>
> <contact>
>    <name>
>    <address></address>
>    <telephone>
>       <number></number>
>    </telephone>
>    <telephone>
>       <number></number>
>    </telephone>
> </contact>
> </Doc>
--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: mulitple repeated items

Colin Seaman
Thanks Erik, although I've been unable to do exactly what I want to do. 

In my example, every time I add a new inner line item, each line item receives one extra inner line item.  I want to make it so that only the particular node selected receives the inner line item.  I'm presuming its something to do with the nodeset  in the triggers, can't can't specifically find what.

Any help appreciated; attached is a sandbox file too!
Colin Seaman
Senior Developer
 
Tradocs Ltd,
Tower Point,
44 North Road,
Brighton,
BN1 1YR

email:     [hidden email]
skype:     colin,seaman
telephone: 0870-1417031
website:   http://www.tradocs.net

This email and any files transmitted with it are confidential 
and intended solely for the use of the individual or entity to 
whom they are addressed. If you have received this email in 
error please contact Tradocs. Please note that any views or 
opinions presented in this email are solely those of the author 
and do not necessarily represent those of the company. Finally, 
the recipient should check this email and any attachments for 
the presence of viruses. The company accepts no liability for 
any damage caused by any virus transmitted by this email.
This content of this email is without prejudice.


Erik Bruchez wrote:
Colin,

The To-Do Lists example shows something like this.

-Erik

Colin Seaman wrote:
Guys,

Has anyone got a good example of a repeat within a repeat within an xform?  Something like:

<Doc>
<contact>
   <name>
   <address></address>
   <telephone>
      <number></number>
   </telephone>
   <telephone>
      <number></number>
   </telephone>
</contact>
<contact>
   <name>
   <address></address>
   <telephone>
      <number></number>
   </telephone>
   <telephone>
      <number></number>
   </telephone>
</contact>
</Doc>


-- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: [hidden email] For general help: [hidden email] ObjectWeb mailing lists service home page: http://www.objectweb.org/wws


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws

multiloop.xhtml (5K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: mulitple repeated items

Alessandro  Vernet
Administrator
Hi Colin,

I am not sure to understand the problem. Running the example in the
sandbox, see attached what I get after clicking on the button Add Line
Item. Is this not what you expected? Do you see something different?

Alex

On 1/4/07, Colin Seaman <[hidden email]> wrote:

>
>  Thanks Erik, although I've been unable to do exactly what I want to do.
>
>  In my example, every time I add a new inner line item, each line item
> receives one extra inner line item.  I want to make it so that only the
> particular node selected receives the inner line item.  I'm presuming its
> something to do with the nodeset  in the triggers, can't can't specifically
> find what.
>
>  Any help appreciated; attached is a sandbox file too!
>  Colin Seaman
> Senior Developer
>
> Tradocs Ltd,
> Tower Point,
> 44 North Road,
> Brighton,
> BN1 1YR
>
> email: [hidden email]
> skype: colin,seaman
> telephone: 0870-1417031
> website: http://www.tradocs.net
>
> This email and any files transmitted with it are confidential
> and intended solely for the use of the individual or entity to
> whom they are addressed. If you have received this email in
> error please contact Tradocs. Please note that any views or
> opinions presented in this email are solely those of the author
> and do not necessarily represent those of the company. Finally,
> the recipient should check this email and any attachments for
> the presence of viruses. The company accepts no liability for
> any damage caused by any virus transmitted by this email.
> This content of this email is without prejudice.
>
>
>  Erik Bruchez wrote:
> Colin,
>
>  The To-Do Lists example shows something like this.
>
>  -Erik
>
>  Colin Seaman wrote:
>
> Guys,
>
>  Has anyone got a good example of a repeat within a repeat within an xform?
> Something like:
>
>  <Doc>
>  <contact>
>     <name>
>     <address></address>
>     <telephone>
>        <number></number>
>     </telephone>
>     <telephone>
>        <number></number>
>     </telephone>
>  </contact>
>  <contact>
>     <name>
>     <address></address>
>     <telephone>
>        <number></number>
>     </telephone>
>     <telephone>
>        <number></number>
>     </telephone>
>  </contact>
>  </Doc>
>
>  ________________________________
>
>
> --
> You receive this message as a subscriber of the [hidden email]
> mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>
> --
> You receive this message as a subscriber of the [hidden email]
> mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>
>

--
Blog (XML, Web apps, Open Source):
http://www.orbeon.com/blog/


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws

repeat.png (11K) Download Attachment
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Reply | Threaded
Open this post in threaded view
|

Re: mulitple repeated items

Colin Seaman
Hi Alex,

If you add a few inner line items before adding a new line item, and then add some inner line items afterwards, you'll see that inner line items get added to all blocks and new line items don't start with the default 1 inner line items.

Eek!
Colin Seaman
Senior Developer
 
Tradocs Ltd,
Tower Point,
44 North Road,
Brighton,
BN1 1YR

email:     [hidden email]
skype:     colin,seaman
telephone: 0870-1417031
website:   http://www.tradocs.net

This email and any files transmitted with it are confidential 
and intended solely for the use of the individual or entity to 
whom they are addressed. If you have received this email in 
error please contact Tradocs. Please note that any views or 
opinions presented in this email are solely those of the author 
and do not necessarily represent those of the company. Finally, 
the recipient should check this email and any attachments for 
the presence of viruses. The company accepts no liability for 
any damage caused by any virus transmitted by this email.
This content of this email is without prejudice.


Alessandro Vernet wrote:
Hi Colin,

I am not sure to understand the problem. Running the example in the
sandbox, see attached what I get after clicking on the button Add Line
Item. Is this not what you expected? Do you see something different?

Alex

On 1/4/07, Colin Seaman [hidden email] wrote:

 Thanks Erik, although I've been unable to do exactly what I want to do.

 In my example, every time I add a new inner line item, each line item
receives one extra inner line item.  I want to make it so that only the
particular node selected receives the inner line item.  I'm presuming its
something to do with the nodeset  in the triggers, can't can't specifically
find what.

 Any help appreciated; attached is a sandbox file too!
 Colin Seaman
Senior Developer

Tradocs Ltd,
Tower Point,
44 North Road,
Brighton,
BN1 1YR

email: [hidden email]
skype: colin,seaman
telephone: 0870-1417031
website: http://www.tradocs.net

This email and any files transmitted with it are confidential
and intended solely for the use of the individual or entity to
whom they are addressed. If you have received this email in
error please contact Tradocs. Please note that any views or
opinions presented in this email are solely those of the author
and do not necessarily represent those of the company. Finally,
the recipient should check this email and any attachments for
the presence of viruses. The company accepts no liability for
any damage caused by any virus transmitted by this email.
This content of this email is without prejudice.


 Erik Bruchez wrote:
Colin,

 The To-Do Lists example shows something like this.

 -Erik

 Colin Seaman wrote:

Guys,

 Has anyone got a good example of a repeat within a repeat within an xform?
Something like:

 <Doc>
 <contact>
    <name>
    <address></address>
    <telephone>
       <number></number>
    </telephone>
    <telephone>
       <number></number>
    </telephone>
 </contact>
 <contact>
    <name>
    <address></address>
    <telephone>
       <number></number>
    </telephone>
    <telephone>
       <number></number>
    </telephone>
 </contact>
 </Doc>

 ________________________________


--
You receive this message as a subscriber of the [hidden email]
mailing list.
To unsubscribe: [hidden email]
For general help: [hidden email]
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws



--
You receive this message as a subscriber of the [hidden email]
mailing list.
To unsubscribe: [hidden email]
For general help: [hidden email]
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws










-- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: [hidden email] For general help: [hidden email] ObjectWeb mailing lists service home page: http://www.objectweb.org/wws


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: mulitple repeated items

Alessandro  Vernet
Administrator
Colin,

This is normal, because the <xforms:insert> makes a copy of the last
LineItem in your nodeset. So if you add inner line items, and then run
the <xforms:insert>, you will end up with the additional inner line
items in the copy.

One way to solve this problem to have an empty line item in a separate
instance, and use the 'origin' attribute on the <xforms:insert> to say
that this is the line item you want to copy.

Alex

On 1/10/07, Colin Seaman <[hidden email]> wrote:

>
>  Hi Alex,
>
>  If you add a few inner line items before adding a new line item, and then add some inner line items afterwards, you'll see that inner line items get added to all blocks and new line items don't start with the default 1 inner line items.
>
>  Eek!
>  Colin Seaman
> Senior Developer
>
> Tradocs Ltd,
> Tower Point,
> 44 North Road,
> Brighton,
> BN1 1YR
>
> email:     [hidden email]
> skype:     colin,seaman
> telephone: 0870-1417031
> website:   http://www.tradocs.net
>
> This email and any files transmitted with it are confidential
> and intended solely for the use of the individual or entity to
> whom they are addressed. If you have received this email in
> error please contact Tradocs. Please note that any views or
> opinions presented in this email are solely those of the author
> and do not necessarily represent those of the company. Finally,
> the recipient should check this email and any attachments for
> the presence of viruses. The company accepts no liability for
> any damage caused by any virus transmitted by this email.
> This content of this email is without prejudice.
>
>
>  Alessandro Vernet wrote:
>
> Hi Colin,
>
>  I am not sure to understand the problem. Running the example in the
>  sandbox, see attached what I get after clicking on the button Add Line
>  Item. Is this not what you expected? Do you see something different?
>
>  Alex
>
>  On 1/4/07, Colin Seaman <[hidden email]> wrote:
>
>
>   Thanks Erik, although I've been unable to do exactly what I want to do.
>
>   In my example, every time I add a new inner line item, each line item
>  receives one extra inner line item.  I want to make it so that only the
>  particular node selected receives the inner line item.  I'm presuming its
>  something to do with the nodeset  in the triggers, can't can't specifically
>  find what.
>
>   Any help appreciated; attached is a sandbox file too!
>   Colin Seaman
>  Senior Developer
>
>  Tradocs Ltd,
>  Tower Point,
>  44 North Road,
>  Brighton,
>  BN1 1YR
>
>  email: [hidden email]
>  skype: colin,seaman
>  telephone: 0870-1417031
>  website: http://www.tradocs.net
>
>  This email and any files transmitted with it are confidential
>  and intended solely for the use of the individual or entity to
>  whom they are addressed. If you have received this email in
>  error please contact Tradocs. Please note that any views or
>  opinions presented in this email are solely those of the author
>  and do not necessarily represent those of the company. Finally,
>  the recipient should check this email and any attachments for
>  the presence of viruses. The company accepts no liability for
>  any damage caused by any virus transmitted by this email.
>  This content of this email is without prejudice.
>
>
>   Erik Bruchez wrote:
>  Colin,
>
>   The To-Do Lists example shows something like this.
>
>   -Erik
>
>   Colin Seaman wrote:
>
>  Guys,
>
>   Has anyone got a good example of a repeat within a repeat within an xform?
>  Something like:
>
>   <Doc>
>   <contact>
>      <name>
>      <address></address>
>      <telephone>
>         <number></number>
>      </telephone>
>      <telephone>
>         <number></number>
>      </telephone>
>   </contact>
>   <contact>
>      <name>
>      <address></address>
>      <telephone>
>         <number></number>
>      </telephone>
>      <telephone>
>         <number></number>
>      </telephone>
>   </contact>
>   </Doc>
>
>   ________________________________
>
>
>  --
>  You receive this message as a subscriber of the [hidden email]
>  mailing list.
>  To unsubscribe: mailto:[hidden email]
>  For general help: mailto:[hidden email]?subject=help
>  ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>
>  --
>  You receive this message as a subscriber of the [hidden email]
>  mailing list.
>  To unsubscribe: mailto:[hidden email]
>  For general help: mailto:[hidden email]?subject=help
>  ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>
>
>
>
>
>    ________________________________

>       ________________________________

>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
>
>
>



--
Blog (XML, Web apps, Open Source):
http://www.orbeon.com/blog/



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet