-
Notifications
You must be signed in to change notification settings - Fork 6
Description
Context
Currently, this iOS application cannot be published via the app store or TestFlight.
Problem
Challenges meeting the minimum requirements, especially due to an incomplete API.
Solution
Ensure end-to-end utility through a operable UI, a secured API and user session, and a async offline storage method.
Purpose
The purpose of this app is to allow CASA (Court Appointed Special Advocate) volunteers to instantly save vital foster child court report data to their cloud profiles when on the field, anywhere on-the-go, regardless of if they are connected to the internet or not.
Approach
Must-haves:
-
Required iOS app and API [/api/v1/] exchanges
Users can login
- Client sends email and password to server to validate user credentials β Click to View
- Server returns a randomized token in its JSON response β Click to View
Users have a secure and seamless session
- Client gives users option to "stay logged in" to and server keep users logged in until logout β Click to View, β¬ TBD
- Server session tokens in expire in 7 hours β Click to View
- Client sends token to server upon profile update for validation
- Client prompts user to re-sign in if session is expired
Users can view their base profiles
- Client retrieves logged in user profile data from server and displays it
Users can view, add, and update their case contacts
- Client prompts server for logged in user case contact(s) data and displays it
- Server outputs logged in user case contact data
- Client sends server a new logged in user case contact with data
- Server saves new logged in user case contact data to the cloud
- Client provides interface for adding, updating, and saving case contact data
- Server updates old user case contact(s) data on the cloud
Users can sign-out
- Client gives users option to sign-out on account details screen
- Server invalidates current session token if user signs out, requiring re-login
-
Async Offline Storage on iOS app [SQLite, Caching, Upload, Deletion]
User case contact data is stored locally if saved while offline
- Client informs user that upload requires an internet connection, and that data is only saved locally
- Client stores ALL case contact(s) and their data locally in a structured format, via SQLite
Users can view unuploaded case contact data when offline
- Client detects user is offline and still displays user data and their updates (it is ALL stored locally)
- Client displays unuploaded data alert so user is informed an internet connection is required for online upload
User case contact data updates are posted to the cloud while online
- Client attempts upload to server if internet connection is established
- Client deletes and synchronizes relevant local case contact data if upload is successful
-
UI
- Draft data privacy policy agreement
- Add "Stay Logged In" checkbox to login page β Click to View
- Update CaseListScreen with Case details
- Enhance AccountScreen with signed-in user details
Task Board
- Create a reusable card component with title, description/image, optional drop shadow, and optional button displayΒ #72
- Update CaseListScreen with Case details using new card componentΒ #55
- Add "Stay Logged In" checkbox to login page and alert users that session will be valid until they sign-outΒ #73
- Ensure Sign-In button does not hit endpoint when LoginScreens auth form has no entryΒ #75
- User gets signed-out if session token is invalidΒ #74
- Personalized fun user greeting upon sign-in ( Γ la, "Hello, Tim Cook! Looking handsome as always." )Β #76
- Draft data privacy policy agreementΒ #77
- User case contact data from the server is displayed on CaseContactListScreen
- User case contact alert UI saying an internet connection is required for upload
- Create this wiki page
- Warn the user if case contact is only saved locally
Advanced
- Users can add new case contacts
- Users can update old case contacts
- Client stores ALL case contact(s) and their data locally in a structured format, via SQLite as a backup
- Ensure when client detects user is offline it still displays user data and their in-progress updates
- Synchronize relevant local case contact data with server periodically and prompt user to save/discard their in-progress updates
- Case contact will be saved locally if they don't have internet, and uploaded when they do
PR Template(s) (rubyforgood/casa#3641, rubyforgood/casa#3408)