Expression to convert [Group:##] into text

is there an expression to convert this value: [Group:##] into a text field? Our process analytics report saves task assignees as text when they are people and [Group:##] when they are groups, and we are trying to show the text name of the group in a paging grid in the same column as the text assigned person. We've tried the People functions with no success. We are using this feature as part of the task reassignment smart service and everything works as designed except the display of the group. Thanks!...

OriginalPostID-89270

OriginalPostID-89270

  Discussion posts and replies are publicly visible

Parents
  • Hello

    In case you can set the variable you are getting out of the report, If the variable is single value “User or Group” something like this might help.

    if(runtimetypeof(ri!groupOrUser) = tointeger('type!{www.appian.com/.../2009}Group'),
    group(togroup(ri!groupOrUser), "groupName"),
    rule!APN_displayUser(touser(ri!groupOrUser))
    )
    If you have multiple, that is a different story

    ——SOME OTHER IDEA——
    =with(
    local!array: split(stripwith(ri!text, " "), ";"),
    if(isnull(ri!text), {},
    {
    if(ri!returnType="USER", {},
    togroup( extract( ri!text, "[Group:", "]") )
    ),
    if(ri!returnType="GROUP", {},
    touser(index(local!array,
    where(apply(isusernametaken( _), local!array)), {}))
    )
    }
    )
    )
    ————

    I Hope this helps
    Jose
Reply
  • Hello

    In case you can set the variable you are getting out of the report, If the variable is single value “User or Group” something like this might help.

    if(runtimetypeof(ri!groupOrUser) = tointeger('type!{www.appian.com/.../2009}Group'),
    group(togroup(ri!groupOrUser), "groupName"),
    rule!APN_displayUser(touser(ri!groupOrUser))
    )
    If you have multiple, that is a different story

    ——SOME OTHER IDEA——
    =with(
    local!array: split(stripwith(ri!text, " "), ";"),
    if(isnull(ri!text), {},
    {
    if(ri!returnType="USER", {},
    togroup( extract( ri!text, "[Group:", "]") )
    ),
    if(ri!returnType="GROUP", {},
    touser(index(local!array,
    where(apply(isusernametaken( _), local!array)), {}))
    )
    }
    )
    )
    ————

    I Hope this helps
    Jose
Children
No Data