Dynamically label a section in repeated section from a repeated grid control value.

19 views
Skip to first unread message

MANISH

unread,
Sep 13, 2019, 2:34:56 AM9/13/19
to Orbeon Forms
New to Orbeon - need help !

When synchronising content I would also like to add another section in the repeated section whose label should come from the other repeated grid value.

Check the attached file for sample.

According to https://doc.orbeon.com/form-builder/advanced/services-and-actions/synchronize-repeated-content we can synchronise content. Additionally I also want the employee name[1] in repeated grid to be shown as the label of the section[1] under repeated section and employee name [2] as section[2] and so on .

Can anyone help me in achieving this?

Thanks


Sample

Alessandro Vernet

unread,
Sep 13, 2019, 2:46:38 PM9/13/19
to orb...@googlegroups.com
Hi Bojja,

Indeed, the `<fr:synchronize-repeated-content>` you're pointing to seems to
do what you're looking for. But I am not seeing you trying to use it in your
example. So I'd recommend you start by reading the page you point to, and
try to use the `<fr:synchronize-repeated-content>`. And of course, just let
us know if anything in the documentation isn't clear, or if you have any
difficulty in the process.

‑Alex

-----
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
--
Sent from: http://discuss.orbeon.com/

MANISH

unread,
Sep 17, 2019, 8:41:19 PM9/17/19
to Orbeon Forms
Hi Alex - I need to change the labels here. For the same example can i use the below lines?

<fr:synchronize-repeated-content left="grid-2" right="section-2">
            <fr:map left="control-2" right="control-4"/>
                 <fr:map left="control-2" right="section-3/label"/>             
            </fr:synchronize-repeated-content>

I don't see the labels of the repeated section changing dynamically

Thanks

Alessandro Vernet

unread,
Sep 18, 2019, 7:19:47 PM9/18/19
to orb...@googlegroups.com
Hi Bojja,

You can't set the label of a section with
`<fr:synchronize-repeated-content>`, but instead you can make the label of
the section depend on a value inside the section. In your example, you're
"setting" the value of `control-4` inside `section-2`. You can open the
"Section/Grid Settings" dialog for that section, to the "Label" tab, add a
Template Parameters you name `control-4`, set it to the value of
`control-4`, and in the title use `{$control-4}`.

You'll let me know if this works for you.

MANISH

unread,
Sep 18, 2019, 10:19:49 PM9/18/19
to Orbeon Forms
Thanks Alex- Works perfect for me!

Alessandro Vernet

unread,
Sep 19, 2019, 2:38:37 AM9/19/19
to orb...@googlegroups.com
Great, Bojja! I'm glad using a template for the section title worked, and
thank you for the follow-up.
Reply all
Reply to author
Forward
0 new messages