Skip to main content
I would like members from the Opportunity Teams from Team Role 'Solutions Consultant' only, to be displayed on an HTML Visualforce email template.

I would like the code to have the same format as:

<pre>

                  </tr>

                   <tr > 

                     <td bgcolor="⌗00A6C3"><font color="⌗FFFFFF"><b><i>Lead Source:</i></b></font></td>

                     <td>{!relatedTo.LeadSource}  </td> 

                  </tr>

                  <tr > 

</pre>
1 respuesta
  1. 26 abr 2018, 12:29
    Hi Serena,

    Assuming Opportunity is the "relatedTo" attribute, you can do this without a component or controller:

    <apex:repeat value="{!relatedTo.OpportunityContactRoles}" var="oppConRole">

    <apex:outputText rendered="{!oppConRole.Role='Solutions Consultant'}">

    <tr><td>{!oppConRole.Contact.Name}</td></tr>

    </apex:outputText>

    </apex:repeat>

    Hope this helps.

    Kindly mark this as solved if the reply was helpful so that it gets removed from the unanswered queue which results in helping others who are encountering a similar issue.

    Regards,

    Nagendra

     
0/9000