How to Pull Staff Related Data for a Remedyforce Task Email Template from the Associated Remedyforce Incident

Version 1
    Share:|

    This document contains official content from the BMC Software Knowledge Base. It is automatically updated when the knowledge article is modified.


    PRODUCT:

    Remedyforce Service Desk



    QUESTION:

    How to Pull Staff Related Data for a Remedyforce Task Email Template from the Associated Remedyforce Incident


    ANSWER:

    How to Pull Staff Related Data for a Remedyforce Task Email Template from the Associated Remedyforce Incident

    To Create the Task Visualforce Template with Staff information from the associated Incident:

    1. Go to Setup | Communication Templates | Email Templates
    2. Click New Template | Tick Visualforce | Click Next
    3. Enter the following:

    Available For Use: True
    Email Template Name: <As Desired>
    Template Unique Name: <As_Desired>
    Email Subject: <As Desired>
    Recipient Type: User
    Related to Type: BMCServiceDesk__Task__c

    4. Click Save
    5. Click Edit Template
    6. Replace after the first line and before the last line with the following:

    <messaging:htmlEmailBody >
    <html>
       <body>
    <b>Test Section Visualforce Template</b><br/>
    Incident Number: {!relatedto.BMCServiceDesk__FKIncident__r.Name}<br/>
    Incident Owner: {!relatedto.BMCServiceDesk__FKIncident__r.Owner}<br/>
    Incident Staff: {!relatedto.BMCServiceDesk__FKIncident__r.BMCServiceDesk__FKOpenBy__c}<br/>
    Incident Staff Username: {!relatedto.BMCServiceDesk__FKIncident__r.BMCServiceDesk__FKOpenBy__r.Username}<br/>
    Incident Staff First Name: {!relatedto.BMCServiceDesk__FKIncident__r.BMCServiceDesk__FKOpenBy__r.LastName}<br/>
    Incident Staff Last Name: {!relatedto.BMCServiceDesk__FKIncident__r.BMCServiceDesk__FKOpenBy__r.FirstName}<br/>
        </body>
    </html>
    </messaging:htmlEmailBody>


    7. Click Save.
    8. Test the template to verify the desired fields contain the required data.


    Article Number:

    000150217


    Article Type:

    FAQ/Procedural



      Looking for additional information?    Search BMC Support  or  Browse Knowledge Articles