Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • A JavaScript program must be created to run on the app.
  • The JavaScript program must use a Rich Display screen saved as a JSON file.
  • A "Sync" web service is needed to sync the collected data back to the server.
  • JavaScript and JSON files must be stored in the IFS at the Profound UI instance folders userdata/js folder
    • For a standard instance installation the path is is /www/profoundui/htdocs/profoundui/userdata/js/
  • The JavaScript program may have any functionality you wish but must include the following methods:
    • run(displayData, connection, callback) - Called when connection name is tapped and should include the application code.

    • sync(connection, callback) - Called when the Sync icon is tapped and should contain the code to contact the server web service and send and/or receive data.

    • isSyncNeeded() - Should contain code to determine if there is data that needs to be synced back to the server.

...

The default names for the JavaScript and JSON files are puimobile_default.js and puimobile_default.json.

To create multiple programs, you will need to use the Parameter field which then becomes part of the file names.

For example: If you enter Orders in the Parameter field during connection setup, you would need the file names to be puimobile_orders.js and puimobile_orders.json.

Examples:

More details and sample code can be found in our Sample projects:

There are two offline mobile examples available. Both examples use the same JavaScript program and example files.

The only difference between the two examples is that one uses a Profound.js web service and the other uses a Profound UI Universal Display program for the web service

Universal Display version: https://github.com/ProfoundLogic/offline-mobile-universal-displayproject:


Profound.js version: https://github.com/ProfoundLogic/offline-mobile-sample