Symantec IGA

Expand all | Collapse all

Displaying a multivalued custom data element into multi lines in email

  • 1.  Displaying a multivalued custom data element into multi lines in email

    Posted Feb 13, 2017 10:57 AM

    We have a custom data element in an email policy which returns a list of all roles a user is a member of :

     

    So the Final role list data element might have somethign like <RoleName1>,<RoleName2>,<RoleName3>,<RoleName4>

    dispalyed in a single line and we want to split it into multiple rows.

     

    I tried using s javscript to split it based on occurance of comma but it didnt work, neither putting simply <BR> tag worked.

     

    Anyone has any tips on this.

     

    Thanks



  • 2.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 12:11 AM

    Hello,

    You can create another custom data element to parser the membership list and separate each of the role.

    Below is an example that works in my environment:

     

     

    The first one is to retrieve the user's membership. I assume you have something similar.

    The second one is to remove the delimiter and add a carriage return, below is the configuration:

     

    Please note, membership list has this format: abc^def^ghi.

    You need to provide correct delimiter in your membership to the sub-string to be replaced, i.e coma

     

    Cheers

    Lien



  • 3.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 01:48 AM

    we had tried that but it disaplayed the <br /> instead of seperating. Have you tried displaying the email with this.



  • 4.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 01:52 AM



  • 5.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 02:01 AM

    hmm...that's a bit odd.

    This is what I got from the email:

     

     

    What is the IM version that you have?

    Can you share the email policy setup?



  • 6.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 02:12 AM

    12.6 SP4. Actually I cant share it since its not test email policy but if you could share your test email template it woudl be of great help.



  • 7.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 02:14 AM



  • 8.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 02:10 AM

    Looks like when <br /> element is part of {'role_lis'} it being considered  a part of the string rather than part of html element. I have also tried putting '<br />' and ''<br />'' but it just dispalyes as it it.



  • 9.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 02:38 AM

    I saw in the log the following:

     

    "PX_GENERATED_DYN_DATA_DYNAMIC_CUSTOM-Final_Role_List": Test_GD6&#60;br /&#62;Test_GD&#60;br /&#62;Test_GD4



  • 10.  Re: Displaying a multivalued custom data element into multi lines in email
    Best Answer

    Posted Feb 14, 2017 02:51 AM

    This issue is fixed in 12.6.08 

     

    00174794 IM Server Email sent through Policy Express is not displayed properly if the email body contains angular brackets, that is, < and >.



  • 11.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 14, 2017 05:53 PM

    I am glad you found the version that fixed the issue.

    My environment is also R12.6 SP4 and the <br /> tag works fine for me. The difference between our configuration is: you have policy express to send emails, I directly setup and test the email policy: System --> Email --> Create Email.



  • 12.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 16, 2017 04:10 AM

    I am not uding policy xpress I also have email policy i.e System>Email>Create email



  • 13.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 16, 2017 04:11 AM

    Even when you create an email and use custom data elements , i guess in the backend its still PX_GENERATED_DYN_DATA_DYNAMIC_CUSTOM-<element name> which is calculated.



  • 14.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 16, 2017 04:31 AM

    Could you send me the xml of you email policy which works with the br element.



  • 15.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 16, 2017 06:34 PM

    Here is the xml for the email policy I setup:

     

     <ManagedObject type="EMAIL EXPORT" friendlyName="Role Change Notification">
      <Attribute name="friendlyName">Role Change Notification</Attribute>
      <Attribute name="enabled">false</Attribute>
      <Attribute name="category">Roles</Attribute>
      <Attribute name="description"></Attribute>
      <Attribute name="runOnce">false</Attribute>
      <Attribute name="priority">0</Attribute>
      <Attribute name="type">EVENT</Attribute>
      <Attribute name="system">false</Attribute>
      <Attribute name="template">Email</Attribute>
      <Attribute name="templateData"></Attribute>
      <Attribute name="whenToRun"><![CDATA[<Related>
    <WhenToRun>
    <Attribute name="type">SUBMITTED_TASK</Attribute>
    <Attribute name="step">TASK_COMPLETED</Attribute>
    <Attribute name="eventName">ModifyUser</Attribute>
    </WhenToRun>
    </Related>
    ]]></Attribute>
      <Attribute name="dataElements"><![CDATA[<Related>
    <DataElement>
    <Attribute name="friendlyName">New Role List</Attribute>
    <Attribute name="elementType">element.type.string.parser</Attribute>
    <Attribute name="subElement">element.string.manipulation.replace.all</Attribute>
    <Attribute name="priority">1</Attribute>
    <PxParameter extraInfo="" index="1" uiType="TYPED">{'Role_List'}</PxParameter>
    <PxParameter extraInfo="" index="2" uiType="TYPED">^</PxParameter>
    <PxParameter extraInfo="" index="3" uiType="TYPED">&lt;br /&gt;</PxParameter>
    </DataElement>
    <DataElement>
    <Attribute name="friendlyName">PX_GENERATED_RECIPIENT_RECIPIENT_STATIC-test.user@ca.com</Attribute>
    <Attribute name="elementType">element.type.constant</Attribute>
    <Attribute name="subElement">element.constant.get</Attribute>
    <Attribute name="priority">-1</Attribute>
    <PxParameter extraInfo="" index="1" uiType="TYPED">test.user@ca.com</PxParameter>
    </DataElement>
    <DataElement>
    <Attribute name="friendlyName">PX_GENERATED_DYN_DATA_DYNAMIC_CUSTOM-New Role List</Attribute>
    <Attribute name="elementType">element.type.constant</Attribute>
    <Attribute name="subElement">element.constant.get</Attribute>
    <Attribute name="priority">-1</Attribute>
    <PxParameter extraInfo="" index="1" uiType="TYPED">{'New Role List'}</PxParameter>
    </DataElement>
    <DataElement>
    <Attribute name="friendlyName">PX_GENERATED_DYN_DATA_DYNAMIC_ATTRIBUTE-manager</Attribute>
    <Attribute name="elementType">element.type.user.attribute</Attribute>
    <Attribute name="subElement">element.user.attribute.get</Attribute>
    <Attribute name="priority">-1</Attribute>
    <PxParameter extraInfo="" index="1" uiType="SELECTED">manager</PxParameter>
    </DataElement>
    <DataElement>
    <Attribute name="friendlyName">PX_GENERATED_DYN_DATA_DYNAMIC_ATTRIBUTE-%USER_ID%</Attribute>
    <Attribute name="elementType">element.type.user.attribute</Attribute>
    <Attribute name="subElement">element.user.attribute.get</Attribute>
    <Attribute name="priority">-1</Attribute>
    <PxParameter extraInfo="" index="1" uiType="SELECTED">%USER_ID%</PxParameter>
    </DataElement>
    <DataElement>
    <Attribute name="friendlyName">Role_List</Attribute>
    <Attribute name="elementType">element.type.admin.roles.membership</Attribute>
    <Attribute name="subElement">element.admin.roles.get</Attribute>
    <Attribute name="priority">0</Attribute>
    </DataElement>
    </Related>
    ]]></Attribute>
      <Attribute name="entryRules"><![CDATA[<Related/>
    ]]></Attribute>
      <Attribute name="actionRules"><![CDATA[<Related>
    <ActionRule>
    <Attribute name="friendlyName">Email rule</Attribute>
    <Attribute name="priority">0</Attribute>
    <Attribute name="description"/>
    <Conditions/>
    <AddActions>
    <ActionElement>
    <Attribute name="friendlyName">Send email</Attribute>
    <Attribute name="actionType">action.name.send.mail</Attribute>
    <Attribute name="subAction">action.mail.mail</Attribute>
    <Attribute name="priority">0</Attribute>
    <PxParameter extraInfo="" index="1" uiType="TYPED">{'PX_GENERATED_RECIPIENT_RECIPIENT_STATIC-test.user@ca.com'}</PxParameter>
    <PxParameter extraInfo="" index="2" uiType="TYPED"/>
    <PxParameter extraInfo="" index="3" uiType="TYPED"/>
    <PxParameter extraInfo="" index="4" uiType="TYPED">Role Change Notification Email</PxParameter>
    <PxParameter extraInfo="" index="5" uiType="TYPED">&#13;
    &lt;html&gt;&#13;
      &lt;head&gt;&#13;
    &#13;
    &#13;
      &lt;/head&gt;&#13;
      &lt;body&gt;&#13;
        &lt;p&gt;Dear {'PX_GENERATED_DYN_DATA_DYNAMIC_ATTRIBUTE-manager'},&lt;/p&gt;&#13;
        &lt;p&gt;This is the final admin role membership list for {'PX_GENERATED_DYN_DATA_DYNAMIC_ATTRIBUTE-%USER_ID%'}:&lt;/p&gt;&#13;
        &lt;p&gt;{'PX_GENERATED_DYN_DATA_DYNAMIC_CUSTOM-New Role List'}&lt;/p&gt;&#13;
        &lt;p&gt;Thank you&lt;/p&gt;&#13;
      &lt;/body&gt;&#13;
    &lt;/html&gt;</PxParameter>
    </ActionElement>
    </AddActions>
    <RemoveActions/>
    </ActionRule>
    </Related>
    ]]></Attribute>
     </ManagedObject>



  • 16.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 20, 2017 05:07 AM

    Strangely enough with your policy structure as welll I got the following:

     

    Dear ,

    This is the final admin role membership list for t_rr10:

    End User<br />Admin User

    Thank you



  • 17.  Re: Displaying a multivalued custom data element into multi lines in email

    Posted Feb 22, 2017 06:34 PM

    I think it is better you open a support ticket so that we can take a more closer look into your environment :-)