Groups assigned for a task are displaying as [Group:102] rather than Group name

I tried searching Forum already but did not find solution for this. I am following current best practices and using a!queryProcessAnalytics to display a Portal Report in Tempo, however the Groups assigned for a task are displaying as [Group:102] rather than Group name.

I am following the R7.9 Task Report Tutorial which does include how to do special handling for Task Status and Task Details, but for some bizarre reason not Task Assigned Groups. It can not be handled they way Status and Details are as there is no special column config formatting for groups as it is text.

Please help. Thanks.

OriginalPostID-150105

OriginalPostID-150105

  Discussion posts and replies are publicly visible

Parents
  • @greggl Could you please try following snippet:

    if(
    ri!columnConfig.configuredFormatting = "USER_OR_GROUP_NAME",
    apply(
    rule!getFormattedUserOrGroupName(
    userOrGroup: _
    ),
    local!columnData
    )
    )

    Few things to note:
    1. As already discovered by you, there is no need of converting the data into text by using rule!displayTextCell(). Because first of all, we should actually capture the data given by Appian in a specific format without modification, especially in case of User or Group/ Group objects. If you convert the data before hand into string, there after converting back into User or Group object, and then split the values into User objects and Group objects may not be possible.

    if(
    ri!columnConfig.configuredFormatting = "USER_OR_GROUP_NAME",
    apply(
    rule!getFormattedUserOrGroupName(
    userOrGroup: _
    ),
    local!columnData
    )
    )

    2. There isn't a need of using rule!displayTextCell() finally because the same functionality is already done by getFormattedUserOrGroupName in the last step using joinarray which converts an array into string with the desired separator.

    3. I would like to suggest to maintain the user object or group object (For instance, task assignees, task owners, task assignee owner etc) in portal reports in 'User or Group' format i.e. configure the type of the column in the portal report as 'User or Group'. This simplifies the read operations as well as modifications (For instance, formatting a task owner to display first name and last name or converting the task assignees (combination of user objects and group objects) to their respective formatted names) at a later stage.

    4. The intention of rule!displayTextCell() is to convert an array of values which a record holds for an attribute, to plain text. This is to avoid the mismatch in the number of rows raised in case of flattening of arrays. It isn't necessary to use this rule finally as a wrapper, infact your formatted rule (for instance, getFormattedUserOrGroupName can take care of this conversion and infact we can add the desired separators as well) can take care of the conversion.


    Please do let me know if you have any follow-up questions.
Reply
  • @greggl Could you please try following snippet:

    if(
    ri!columnConfig.configuredFormatting = "USER_OR_GROUP_NAME",
    apply(
    rule!getFormattedUserOrGroupName(
    userOrGroup: _
    ),
    local!columnData
    )
    )

    Few things to note:
    1. As already discovered by you, there is no need of converting the data into text by using rule!displayTextCell(). Because first of all, we should actually capture the data given by Appian in a specific format without modification, especially in case of User or Group/ Group objects. If you convert the data before hand into string, there after converting back into User or Group object, and then split the values into User objects and Group objects may not be possible.

    if(
    ri!columnConfig.configuredFormatting = "USER_OR_GROUP_NAME",
    apply(
    rule!getFormattedUserOrGroupName(
    userOrGroup: _
    ),
    local!columnData
    )
    )

    2. There isn't a need of using rule!displayTextCell() finally because the same functionality is already done by getFormattedUserOrGroupName in the last step using joinarray which converts an array into string with the desired separator.

    3. I would like to suggest to maintain the user object or group object (For instance, task assignees, task owners, task assignee owner etc) in portal reports in 'User or Group' format i.e. configure the type of the column in the portal report as 'User or Group'. This simplifies the read operations as well as modifications (For instance, formatting a task owner to display first name and last name or converting the task assignees (combination of user objects and group objects) to their respective formatted names) at a later stage.

    4. The intention of rule!displayTextCell() is to convert an array of values which a record holds for an attribute, to plain text. This is to avoid the mismatch in the number of rows raised in case of flattening of arrays. It isn't necessary to use this rule finally as a wrapper, infact your formatted rule (for instance, getFormattedUserOrGroupName can take care of this conversion and infact we can add the desired separators as well) can take care of the conversion.


    Please do let me know if you have any follow-up questions.
Children
No Data