Building a mobile app using OpenUI5 and Cordova using framework like

jQueryWeb DevelopmentFront End Technology

You are thinking correctly for your requirement. What you can do is, use the read method for each entityset to read the oData. In the success callback for this method, you can parse the result objects into a corresponding JSON model.

Now, you can have working logic as per which:

  • When you online, uses the additional layer to fill the JSON model from the oData that has been read
  • When offline, you can read from local storage.
Updated on 18-Dec-2019 08:26:42