To allow the Alfresco Content Connector to appear in the Lightning experience view of Salesforce you need to add a Salesforce lightning component.
Make sure that you've downloaded the Alfresco Content Connector app, as described in Step 2: Install the app in Salesforce. You need administrator rights to make these changes. You also need to have a custom Salesforce domain that has been deployed and activated for your users, for more see Configure SSO for Salesforce.
To create the Lightning Component follow these steps:
-
Login to Salesforce Lightning view with an administrator account.
-
Click the gear icon
from the top-right toolbar on the Salesforce page and select Developer Console.
-
Go to File > New > Lightning Component.
You will see the New Lightning Bundle window.
-
Enter a Name and a Description and click Submit.
Note
You do not need to select any of the check boxes.
-
Select the Component part of the bundle by clicking COMPONENT in the right hand pane.
-
Remove any code already in there, and copy and paste the following code snippet into the window.
<aura:component implements="flexipage:availableForRecordHome,force:hasRecordId,force:hasSObjectName"> <aura:attribute name="canvasParameters" type="string" /> <aura:handler name="init" value="{!this}" action="{!c.doInit}"/> <force:canvasApp developerName="THE NAME OF YOUR CANVAS APP" height="450px" width="1300px" parameters="{!v.canvasParameters}"/> </aura:component> -
Edit the code and add the name of your Canvas App as the value of the
developerNameproperty. -
Select the Controller part of the bundle by clicking CONTROLLER in the right hand pane.
-
Remove any code already in there, and copy and paste the following code snippet into the window.
({ doInit : function(cmp, evt, helper) { var recordId = cmp.get("v.recordId"); var sObjectName = cmp.get("v.sObjectName"); cmp.set("v.canvasParameters", JSON.stringify({ recordId: recordId, type: sObjectName })); } }) -
Click File and Save All.
-
Edit your Record page by clicking the gear icon
and then clicking Edit.
-
Under the Custom heading in the left hand pane drag over and then drop the component into the desired location on the Activity tab of the Record page.
Note
If your Component is not visible you will see a message that will instruct you to deploy your domain.
-
Click the Activation button on the top right, to activate your change.
Review the Activation Opportunity Record Page and assign the level you want for this component.
-
Click Close.
-
Click the Save button on the top right and then the Salesforce Back button directly above it.
The component is now ready to use.