• Heather Palosaari 12
  • NEWBIE
  • 0 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 1
    Replies
How do you override the standard "Add Opportunity Team Members" button with a lightning component. The options for a lightning override are not showing, I can see them for the edit button but not for the button: OppTeamMemberMultiEdit or for the standard "Add" button.  I can only see the options for the standard "Edit" button on Opportunity Team Members.
Scenario: I created a simple html table on an embedded visualforce page that displays data from the record it is on.  When the user clicks a row it takes them to a report that is filtered by the record ID to show them more information.  I need it to open a new window when on the browser (this works) and navigate inside the Salesforce1 app to the report on mobile (this does not work, it opens a new browser window).  

I know I will need an if statement later to determine where they are opening it (browser or Salesforce1) but for now I can't even get it to work in SF1 properly to worry about that yet.
 This is what I have tried:

**Please note the first row <tr> I tired using a variable - this failed miserably probably for obvious reasons.  The second row <tr> works but opens up a browser window in mobile**
<apex:page standardController="Engagement__c" showHeader="true">
   <script>
    function setupLinks(){
    	var initialContactLink = 'sforce.one.navigateToUrl(/{!$label.report1}?pv0={!Engagement__c.Id})';
    }
        </script>
    <apex:pageBlock >
        
            <table  class="list" border="1" cellpadding="0" cellspacing="0" >
                <thead class="rich-table-thead">
                <tr class="headerRow">
                    <th>Deal Progress</th> 
                    <th>Financial</th>
                    <th>Strategic</th>
                    <th>Total</th>
                </tr>
                </thead>
                <!--The following builds the dashboard table using fields from the Engagement.  The first cell of each row is a hard coded label that links to 
                a specified report for that row. Labels are used to store the individual report SFIDs and they can be edited in Salesforce by going to 
                Setup -> Create -> Custom Labels.  The !ROUND function is being used to display the numbers as whole Integers. -->
                <tr class="dataRow"  >
                    <td class="dataCell" colspan="1"><span><a href="initialContactLink">Initial Contact</a></span></td> 
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Initial_Contact__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Initial_Contact__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Initial_Contact__c + Engagement__c.Strategic_Initial_Contact__c,0)}</span></td>
                </tr>
                <tr class="dataRow">
                    <td class="dataCell" colspan="1"><span><a href="/{!$label.report1}?pv0={!Engagement__c.Id}" target="_blank">Marketing Materials Sent</a> </span> </td> 
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Marketing_Materials_Sent__c, 0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Marketing_Material_Sent__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Marketing_Material_Sent__c + Engagement__c.Financial_Marketing_Materials_Sent__c,0)}</span></td>
                </tr>

 
I have a Google Chart that is a bar chart and displays on a cutsom object.  This is all done with visualforce, and I have it set so clicking on the individual bars takes you to different reports for the custom object.  Is there a way to pass a parameter to a report in a visualforce page without using a URL hack?  The biggest use case for theis chart is mobile so I need a solution that will work there as well.  The below code works in the browser but is unreliable for mobile due to the hack.
var selectHandler = function(e){
var selectedItem = chart.getSelection()[0];
if(selectedItem){
var party = data.getValue(selectedItem.row,0);
}
if(party=='Initial Contact'){
window.open ('https://r.my.salesforce.com/' + ReportID + '?pv0={!Engagement__c.ID'};
}
}
google.visualization.events.addListener(chart, 'select', selectHandler);
};
}
 
Scenario: I created a simple html table on an embedded visualforce page that displays data from the record it is on.  When the user clicks a row it takes them to a report that is filtered by the record ID to show them more information.  I need it to open a new window when on the browser (this works) and navigate inside the Salesforce1 app to the report on mobile (this does not work, it opens a new browser window).  

I know I will need an if statement later to determine where they are opening it (browser or Salesforce1) but for now I can't even get it to work in SF1 properly to worry about that yet.
 This is what I have tried:

**Please note the first row <tr> I tired using a variable - this failed miserably probably for obvious reasons.  The second row <tr> works but opens up a browser window in mobile**
<apex:page standardController="Engagement__c" showHeader="true">
   <script>
    function setupLinks(){
    	var initialContactLink = 'sforce.one.navigateToUrl(/{!$label.report1}?pv0={!Engagement__c.Id})';
    }
        </script>
    <apex:pageBlock >
        
            <table  class="list" border="1" cellpadding="0" cellspacing="0" >
                <thead class="rich-table-thead">
                <tr class="headerRow">
                    <th>Deal Progress</th> 
                    <th>Financial</th>
                    <th>Strategic</th>
                    <th>Total</th>
                </tr>
                </thead>
                <!--The following builds the dashboard table using fields from the Engagement.  The first cell of each row is a hard coded label that links to 
                a specified report for that row. Labels are used to store the individual report SFIDs and they can be edited in Salesforce by going to 
                Setup -> Create -> Custom Labels.  The !ROUND function is being used to display the numbers as whole Integers. -->
                <tr class="dataRow"  >
                    <td class="dataCell" colspan="1"><span><a href="initialContactLink">Initial Contact</a></span></td> 
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Initial_Contact__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Initial_Contact__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Initial_Contact__c + Engagement__c.Strategic_Initial_Contact__c,0)}</span></td>
                </tr>
                <tr class="dataRow">
                    <td class="dataCell" colspan="1"><span><a href="/{!$label.report1}?pv0={!Engagement__c.Id}" target="_blank">Marketing Materials Sent</a> </span> </td> 
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Marketing_Materials_Sent__c, 0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Marketing_Material_Sent__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Marketing_Material_Sent__c + Engagement__c.Financial_Marketing_Materials_Sent__c,0)}</span></td>
                </tr>

 
Scenario: I created a simple html table on an embedded visualforce page that displays data from the record it is on.  When the user clicks a row it takes them to a report that is filtered by the record ID to show them more information.  I need it to open a new window when on the browser (this works) and navigate inside the Salesforce1 app to the report on mobile (this does not work, it opens a new browser window).  

I know I will need an if statement later to determine where they are opening it (browser or Salesforce1) but for now I can't even get it to work in SF1 properly to worry about that yet.
 This is what I have tried:

**Please note the first row <tr> I tired using a variable - this failed miserably probably for obvious reasons.  The second row <tr> works but opens up a browser window in mobile**
<apex:page standardController="Engagement__c" showHeader="true">
   <script>
    function setupLinks(){
    	var initialContactLink = 'sforce.one.navigateToUrl(/{!$label.report1}?pv0={!Engagement__c.Id})';
    }
        </script>
    <apex:pageBlock >
        
            <table  class="list" border="1" cellpadding="0" cellspacing="0" >
                <thead class="rich-table-thead">
                <tr class="headerRow">
                    <th>Deal Progress</th> 
                    <th>Financial</th>
                    <th>Strategic</th>
                    <th>Total</th>
                </tr>
                </thead>
                <!--The following builds the dashboard table using fields from the Engagement.  The first cell of each row is a hard coded label that links to 
                a specified report for that row. Labels are used to store the individual report SFIDs and they can be edited in Salesforce by going to 
                Setup -> Create -> Custom Labels.  The !ROUND function is being used to display the numbers as whole Integers. -->
                <tr class="dataRow"  >
                    <td class="dataCell" colspan="1"><span><a href="initialContactLink">Initial Contact</a></span></td> 
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Initial_Contact__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Initial_Contact__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Initial_Contact__c + Engagement__c.Strategic_Initial_Contact__c,0)}</span></td>
                </tr>
                <tr class="dataRow">
                    <td class="dataCell" colspan="1"><span><a href="/{!$label.report1}?pv0={!Engagement__c.Id}" target="_blank">Marketing Materials Sent</a> </span> </td> 
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Financial_Marketing_Materials_Sent__c, 0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Marketing_Material_Sent__c,0)}</span></td>
                    <td class="dataCell" colspan="1"><span>{!ROUND(Engagement__c.Strategic_Marketing_Material_Sent__c + Engagement__c.Financial_Marketing_Materials_Sent__c,0)}</span></td>
                </tr>