Use connectors in the App Designer

In this topic, you learn how to use a connector in the App Designer.

Using the connectors in the App Designer offers users a range of choices for seamlessly integrating data sources into their applications.

Prerequisites

Procedure

  1. Open your application and search for Connector from the resource library.

  2. Place the component in Resources of the application tree.

  3. In Properties > connector, select your existing connector.

    Ensure you rename the connector component to a logical name that reflects the data source.
  4. In a script, right-click.

    1. Select Code Snippets.

    2. Expand Connectors > NameOfConnector.

      There you will find there the generated scripts for your connector, which are ready for use.

  5. Select a method.

    In this example, we will use the List method to fetch all the data and then bind the attributes to a sap.m.ComboBox containing a one sap.ui.core.Item.

  6. Select the List method and place it in a script.

  7. Remove the filter object key.

    // the name of our connector component is "connectData"
    async function listconnectData() {
        const options = {
            fields: [{
                    name: "name"
                },
                {
                    name: "text"
                },
                {
                    name: "image"
                },
                {
                    name: "updatedAt"
                },
                {
                    name: "createdAt"
                },
                {
                    name: "updatedBy"
                },
                {
                    name: "createdBy"
                }
            ],
            order: {
                name: "DESC"
            },
        };
        const response = await connectData.list(options);
    
        modelComboBox.setData(response.result);  // set the model to the combobox
    }
    listconnectData();
  8. Bind a field to the Properties > text of the sap.ui.core.Item.

    connector bindings

Result

  • Your connector is used in the application and can be bound to components.

connector bindings combobox

Use the External System Connector Bundle

With the Neptune DXP Marketplace item External System Connector Bundle, you can create connectors for the following functionalities:

  • OData services in SAP

  • SAP HANA

  • Salesforce

  • MS SQL Server

  • ServiceNow

  • Neptune DXP - Open Edition system tables