Skip to main content

Configuring an SAP Component in a Lightning Flow

Surface provides multiple Lightning Flow templates (example: SAP Quote Search Flow) that provide process automation for common customer tasks. You can open one of these templates, add your own modifications, and then save your new customized Lightning Flow.

You can create multiple customized flows from a single template to fit your business needs. For example, you can create a flow based on the SAP Order Search Flow that’s customized for your sales department, then create another flow based on the SAP Order Search Flow that’s customized for your customer service department.

NOTE: You can’t modify the Lightning Flow templates that come out of the box with Surface.

Follow these steps to create your own customized Lightning Flow:

  • Navigate to Setup.
  • Use the Setup Quick Find box to search for "Flows", then click the Flows link (under Process Automation).

Select a Flow to Edit

  • Click the name of a Flow that you want to use as the starting point for your new custom Lightning Flow.
  • Your selected flow diagram displays in Salesforce’s Flow Builder.

  • Double click on an element in the flow diagram to display that element’s Edit Screen.

Use the Edit Screen to Modify Components

  • In the Edit Screen, you can:
    • Use the Screen Properties Pane to configure the frame (Show Header and/or Show Footer), control navigation, and provide help text.
    • Drag one or more components from the list in the Screen Components Pane and place them in the Screen Canvas area of the Edit Screen.
    • Click on a component in the Screen Canvas area, then use the Screen Properties Pane to edit the component’s properties.

Save Your Flow

  • Click the Done button to close the Edit Screen.
  • Edit other Flow elements, if desired. After you’ve finished editing Flow elements, click the Save button or the Save As button.

NOTE: If you selected one of the Flow templates that comes out-of-the-box with Surface (example: SAP Delivery Search Flow), only the Save As button will be clickable (the Save button will be ghosted).

Save a New Flow

  • If you selected Save As in Flow Builder, the Save As modal displays.
  • Enter a Flow Label (example: Custom SAP Sales Document Details).
  • Enter a Flow API Name. This is an auto-generated unique name that will be used by the Salesforce API and managed packages (example: if you enter " Custom SAP Sales Document Details " in the Label field, "Custom_SAP_Sales_Document_Details" will be the auto-generated unique name for this field). You can edit this field before you save it.
  • Enter a brief Description (optional) for the new flow.
  • Click the Save button.

Activate a New Flow

After a new flow is created and saved, you must activate it before you can use it.

  • Click the Activate button in Flow Builder to activate the new flow.

Configure Your Lightning Flow Component to use Your Custom Flow Override

  • Go to the Accounts tab.
  • Select an account.
  • Click on the Setup cog icon and click Edit Page to open the Lightning App Builder.
  • Select the Lightning components that you want to use in your custom flow.
  • Enter your custom flow's Flow API Name name (example: SAP_Sales_Document_Details_Custom) in the Override Flow Navigation field. You can find the Flow API Name on the flow's Details and Versions page.​

  • Click the Save button.
  • Click the Back button.
  • Click on the detail link to the left of a document in the list for that component.
  • Your customized detail page should display now.

Add an Action Button to Launch Your Lightning Flow

After you create a custom flow, you may want to add an Action button that allows you to easily launch your custom flow. Salesforce provides this functionality through their Buttons, Links, and Actions.