Develop OData-based Hybrid Apps

The Hybrid App SDK includes the open source Datajs JavaScript library, which you can include as part of your application to access OData stores.

This library, along with the rest of the Hybrid App JavaScript API, is in <SMP_HOME>\MobileSDK<version>\HybridApp\API\Container\Datajs-1.x.x.js.  As of this writing, the latest version of Datajs is 1.0.3.

The Datajs library is used to fetch the data used in your Hybrid App.  This data can be displayed in your Hybrid App using a variety of UI frameworks such as jQuery Mobile, Sencha, or your favorite Web-based UI framework.

Provided the backend OData service has support, you can use the Datajs library to read, modify, and delete data using standard HTTP methods (POST, PUT, DELETE, and so on).

The basic steps for developing an OData-based Hybrid App are:
  1. Add the <SMP_HOME>\UnwiredPlatform \MobileSDK<version>\HybridApp\API\Containers\datajs-1.0.3.js to your Hybrid App.
  2. Create a Hybrid App user interface with your preferred UI framework.
  3. Use the Datajs library for create, read, update, and delete operations to the OData or HTTP end point and bind it to the UI.
  4. Use the packaging tool to generate the manifest.xml file and Hybrid App ZIP package. 
  5. Use the Deploy Wizard in SAP Control Center to deploy the Hybrid App ZIP file.
Related concepts
Develop MBO-based Hybrid Apps
Hybrid App Development Task Flow Using Third-Party Web Frameworks and MBOs
Package Hybrid Apps