Nanoflow Commons ITvisors
Overview
Additional JavaScript actions geared around retrieving data in offline and native apps. Also other stuff that can be quite usable in native mobile apps as well.
Documentation
Description
Additional JavaScript actions geared around retrieving data in offline apps. Also other stuff that can be quite usable in other situations as well. The individual actions are documented in the modeler.
Typical usage scenario
Offline and Mendix Native apps.
To retrieve over an association:
- Get the GUID of the other object using NanoflowCommons.GetGuid
- Use the GUID on any of the GetOffline JS actions as value for the reference
To filter on dates:
- Use nanoflow SUB_DateToEpochUTC to get the internal date value
- Use that value as constraint value
To filter on enum values:
- Use the toString expression function to get the enum key
- Use that value as constraint value
Features and limitations
Available actions:
- Format date/time
- Format decimal
- Get enum key or value
- Get offline first, list and count in a basic and an advanced version
- Get offline database object counts
- Clone object
- Compare objects (of the same entity)
- Calculate distance (in kilometers) between two coordinates.
- Split a string into a list of items
The GetOffline… actions allow data retrieval using combinations we are used to in microflows, but before Mendix 10.13 not possible in nanoflows. For example, retrieve over an association, filter on another attribute and sort the result. Even with Mendix 10.13 and up these actions can be useful, for example when filtering a list with several optional criteria.
The GetOfflineFull… actions allow you to take full advantage of the GetOffline function in the Mendix client. For documentation see the GetOffline documentation in mx.data
The GetOfflineStats action returns object counts for each persistent entity found in the offline database.