Another way to append an object array

Stimulsoft Reports.JS discussion
Post Reply
guilhermetti
Posts: 14
Joined: Tue Oct 11, 2022 4:56 pm

Another way to append an object array

Post by guilhermetti »

Hello everything is fine?
I need help, I want to put the 'List of Access Levels' column like this:
GENERAL DEV TEST, GENERAL SP LEVEL, MAIN LEVEL ACCESS, SHIFT 01

Not as in the attached form. There must be a way?
Attachments
R1PI-1022 (Example 2).mrt
(26.36 KiB) Downloaded 61 times
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: Another way to append an object array

Post by Lech Kulikowski »

Hello,

You can use the JoinColumnContent function:
{JoinColumnContent(data_internalUser_nodes_permanentAccessLevels_accessLevel,"name",",")}

Thank you.
guilhermetti
Posts: 14
Joined: Tue Oct 11, 2022 4:56 pm

Re: Another way to append an object array

Post by guilhermetti »

Sorry, but i dont understand :?

Image
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: Another way to append an object array

Post by Lech Kulikowski »

Hello,

What product and version are you use?

Thank you.
guilhermetti
Posts: 14
Joined: Tue Oct 11, 2022 4:56 pm

Re: Another way to append an object array

Post by guilhermetti »

Version 2021.2.4 from 22 abril 2021, JS
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: Another way to append an object array

Post by Lech Kulikowski »

Hello,

Please check the last release build.

Thank you.
guilhermetti
Posts: 14
Joined: Tue Oct 11, 2022 4:56 pm

Re: Another way to append an object array

Post by guilhermetti »

Alright, now I'm on Release Version 2023.2.5 from 20 May 2023.
But this way it works with a JSON with only one item. When I use at least two items or more a bug happens with the list! Look:

Image

My necessity is that each access level object has a different amount for each person. In this case, the person 'Daniel' has four levels and 'Eliano' has only two.
Can you help me with this please?
I tried this way:
{JoinColumnContent(data_internalUser_nodes,"data_internalUser_nodes.RelationAccessLevels.RelationAccessLevel.name",", ")}
But no success

Kind of like in this thread too:
viewtopic.php?t=56693
Attachments
R1PI-1022.mrt
(27.19 KiB) Downloaded 51 times
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: Another way to append an object array

Post by Lech Kulikowski »

Hello,

Unfortunately, JoinColumnContent is not working with levels by relation, only all data source records.

You can add an additional band, on which prepare string will that level values as in the provided forum link in your post.

Thank you.
guilhermetti
Posts: 14
Joined: Tue Oct 11, 2022 4:56 pm

Re: Another way to append an object array

Post by guilhermetti »

In the topic that I sent as an example, it is not explained in a clear way how it was done, because the mrt was just attached without explanations.
Could you please explain me better? :D
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: Another way to append an object array

Post by Lech Kulikowski »

Hello,

You can use the master-detail construction or an additional variable.

Thank you.
Attachments
JoinColumn.mrt
(23.22 KiB) Downloaded 55 times
Post Reply