Registration Client with flutter
What do we have to start with?
GitHub repository
clientmanager, keymanager, packetmanager and scanlibrary(opencv) modules written in java
Things to start with:
Screen designs
Login (stateless) - the ability to get machine details like name & keys, login form
Settings -
options to choose when to sync data from the server and upload packets to the server.
which network to use - mobile data, wifi or none & data limit.
place to store the packets.
Home -
Registration Tasks (completely depends on process spec and screen spec)
New
Update
Lost
Correction
Manage Packets
sync packet
know the packet status
upload (single / bulk) to the server
Master Data (Only supervisor access)
Display Machine & Center details
Display ID schema & UI spec version & integrity of these JSON files.
if the JSON files are corrupted, need the option to sync
Display metadata of all the entities synced from the server.
Last sync datetime
Number of Entries
CleanUp - option to initiate full sync without losing registration data.
Dashboard (check if this could be rendered based on an HTML template?)
Packet storage status ( disk used and free stats)
Packet creation & sync-upload date-time limit stats
Manage Jobs
Option to alter schedule, trigger check the status of last trigger
Required POC
Flutter framework + MVP + with keymananger java module
Need to document the way to integrate, so that other team members could start on other module integration.
Flutter framework + MVP + DI (we used dagger with native android app v1.0.0)
interface-based dependency injection
Load configuration properties from DB and use it system-wide
Creation of registration form (at runtime) as per the screen-spec.
Note: All the business logic, and DB operations will be part of java modules. and the instances must be injected either into the models/presenter.
Logic in models & presenter should do the:
Filter data based on the logged-in operator and mode of operation(offline/online).
Restrict the operator based on his/her access roles. We support only 2 roles (REGISTRSTION_SUPERVISOR, REGISTRSTION_OPERATOR)
We want to support android and browser-based registration clients.
We will follow MVP pattern: View <--> Presenter <- Model
We will have handler abstract classes (Model)
Required services will be injected into handler Implementation.
LoginHandler - abstract class
1. handle first time login - onboard user
2. handle login - resolve auth-factors (PWD / BIO / OTP)
3. resolve and set the allowed features based on the loggedin operator roles.
4. Give device details - name & public keys
5. Check the device initialization status
All the session details to be stored in scopedModel
Build scopedModel on operator login
1. userid
2. username
3. roles
4. machine
5. center
sessionIdleTime to autologout