Hello Jan,

I can't help you much on your particular problem. But you seem to have nested repeaters working. Maybe you could help Mike with his problem he asked yesterday: http://thread.gmane.org/gmane.text.xml.cocoon.user/31386.

Joerg

On 29.01.2004 16:57, Jan Hoskens wrote:

Hi,

I'm wondering how I can easily copy a row in a repeater. If I have a certain
row with a row-action that does an add-after, I want to have a new row which
has initially the same values.

For example:

My template is showing this: (let the | define simple text inputs shown by
your browser)

|fruit|apple|granny-smith| <row action button/>

Then when I push that row action button I want to see:

|fruit|apple|granny-smith|
|fruit|apple|granny-smith|

So that I only have to change the last input to obtain what I really want:

|fruit|apple|granny-smith|
|fruit|apple|golden|

(this is a simple example of course, picture this with repeaters in
repeaters and so on....)

I thought to do this in the on-activate, but it seems that I have to copy
each widget value explicitly using their name. Isn't there an iterator over
a repeaterrow(well, I did not find one..) so I can just copy the values? Or
another way to do the same?

If I have a row which contains another repeater, then I'll have to create
new rows in the newly created repeater and then retreive each value by
getWidget("").getValue()?

<repeater>
    <repeater> <- I'll have to copy this to the new row, so creating new
rows and each time explicitly get each widget's value and set it in the new
repeater
</repeater>

Greetings,

Jan

--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to