Overview
Running our app in Salesforce1 mobile app is very similar to adding Visualforce tabs to Salesforce1. However there are some requirements and limitations.
Requirements & Limitations
- Components are the integration point, not Apps
- Components must implement force:appHostable
- Styling, sizing, etc. are not provided
- Not integrated with other S1 components
Create A Component
We can only embed a component inside another component but not an app inside another app. Since Salesforce1 app is itself is an app, we need can only embed our component. Create a component.
- Select File > New > Aura Component
- Enter opportunityPanel for the name
- Click Submit
- Select opportunityPanel.cmp
- Add the below markup to your component.
- Change the namespace to yours
- Save the changes
force:appHostableNote: Components must have
implements="force:appHostable"
to embed in Salesforce1 Mobile app.
Create Aura Tabs
Creating an Aura tab is similar to creating a Visualforce tab. If your org has Aura on the platform enabled, you will see Aura Tabs
section for you to add tabs.
- Navigate to Setup in the browser
- Expand Create and select Tabs
- Click the New button in the Aura Tabs section
- Select
<ns>:opportunityPanel
from the Aura selector - Set the Tab Label to
Opportunities (AotP)
- Set the Tab Name to
Opportunities_AotP
- Choose a Tab Style
- Press the Next button
- Press the Save button on the next screen
Setup Mobile Navigation
- Ensure that you are in Setup
- Type “mobile n” in the search box
- Select Mobile Administration -> Mobile Navigation
- Select
Opportunities (AotP)
in the Available list - Click the Add button to move it to the Selected list
- Select
Opportunities (AotP)
) in the Selected list - Press the Up button to move it below People
- Press the Save button
View in Salesforce1 Mobile
Salesforce1 mobile app is runs in https://<your org domain>/one/one.app
. Open Salesforce1 app and click on the “hamburger icon”. You should see your “Opportunities (AotP)” app.