One major requirement for this app is the ability for agents to work offline and synchronize to our cloud servers once they get online. By default ALL data entry should be done ‘offline’ even if there is an internet connection. Trying to save data online on a slow connection might hold up data entry time.
Agents will be required to login with a mobile number and a password. The screen should also have a Reset Password link. The input for entering the mobile number should display ONLY numeric characters. Authentication is handled by Calabash and thus requires an API call to be made. The app should keep agents logged into their devices until they explicitly logout. After logging in for the first time the following data needs to be downloaded and saved to the agent’s device. Agent’s default profile information.
If an agent logs out and logs back in to the same device, all data they previously uploaded should still be on the device. If the agent logging in is different from the one who logged in previously, all data should be purged and new offline data fetched on to the device.
Synchronization should be done automatically when an internet connection is detected and should be a background process that does not interfere with the agent’s work. Agents also have the option of synchronizing manually from the profile screen. An agent need's to know the progress of their synschronization. Ideally, they should know how many of the items pending synchronization have actually synced and how many failed.
Agents should be able to see a list of all failed syncs with the appropriate reason as to why they failed. It should be possible for the agent to retry syncing items that failed.
It is possible for an agent to get assigned more data after they sign in. For example, when an agent is created, no markets were assigned. The agent logs in to their app and pulls in all the offline data. Later on, the agent's supervisor assigns a couple of markets to him. In order for the agent to see these markets on his device, a data refresh needs to be done.
Both Refresh and Synchronization will be done using the same button available on the agent's profile screen.
In This Document