Skip to content
Nur Amin
← All projects
P-04generus-mobile2026

Generus Android — Native Companion App

A native Kotlin version of the Generus PWA on the same Supabase project — offline attendance that still gets sent after the app is closed, an on-device QR scanner, and ID cards drawn on the phone.

My role
Sole developer — Android app and the database API it uses.
Field
Mobile Apps
Stack
  • Kotlin
  • Jetpack Compose
  • Room
  • WorkManager
  • Supabase
  • PostgreSQL
  • CameraX
  • ML Kit

Overview

Generus started as a PWA so iPhone users and laptop dashboards could share one codebase. Its weak spot was background work: on iOS a PWA can only send queued attendance while it is open. An officer who closes the app in a hall with no signal leaves records stranded until the next time they open it.

The Android app covers the same ground as the PWA, on the same Supabase project. There is no new backend. Simple writes go straight to tables through PostgREST, and the joined queries that live in the PWA’s TypeScript became 41 SQL functions that run as the caller, so the same row-level security still decides what each account can see.

Attendance taps and scans land in a Room queue first, keyed by agenda and member so the latest tap wins. The queue is sent when a status is tapped, when the network returns, every 20 seconds while the app is open, and by WorkManager once the app is closed. The scanner reads cards with ML Kit on the device and matches a SHA-256 hash of the QR content against a local roster, so it works with no signal.

In pictures

Generus Android title with three Android phones: the home screen, an attendance checklist, and the QR scanner.
FIG. 01Home, checklist and scanner in the native app. Mockups redrawn with sample data; the app UI is in Indonesian.
Diagram: the Android app and the PWA both connect to one Supabase project — Auth, PostgREST, 41 mobile_* RPC functions, unchanged RLS, and an admin Edge Function — with test and official build flavors below.
FIG. 02A second client with no new backend: the same rules guard both apps.
An Android attendance checklist with two items waiting to send, next to the four triggers that flush the Room queue and a comparison with the PWA on iOS.
FIG. 03Taps are saved on the phone first; WorkManager sends them even after the app is closed.
Three Android scanner screens — recorded in green, already recorded in amber, rejected in red — above the flow from CameraX and ML Kit to a hashed roster lookup.
FIG. 04Three clear answers, each with its own sound and vibration.
A portrait Generus ID card with a QR code, next to an A4 PDF page of nine cards and cards for Excel import and report export.
FIG. 05ID cards drawn on the phone and exported nine to an A4 page; long names are shortened to an initial.

Function

Backend
None new — same Supabase project, RLS and triggers as the PWA
Offline
Room queue, sent by WorkManager even after the app is closed
Scanner
CameraX + ML Kit on the device, with sound and vibration

What it does

  1. 01Home with the ongoing or next gathering, quick actions, monthly attendance and a three-absences-in-a-row warning.
  2. 02Agendas — one-off or weekly — with cancel, lock, and scan officers.
  3. 03Offline checklist with H/T/I/S/A, mark-all-present, and delegated completion for group admins.
  4. 04QR scanner with CameraX and ML Kit, sound and vibration per result, and name search as a fallback.
  5. 05Member records with filters, status changes, transfers, card reissue and bulk level promotion.
  6. 06ID cards drawn on the device and exported as an A4 PDF, nine per sheet, ready to print or share.
  7. 07Excel import validated on the phone, and monthly reports exported to Excel.
  8. 08Curriculum periods, targets and a materials library with Arabic text; achievement checklists and bulk kitab progress.
  9. 09Region and account admin through an Edge Function that holds the service role, plus forced password change on first login.

Technical notes

Builds
Two flavors — test and official server — installable side by side
Target
minSdk 26, targetSdk 36, JDK 17
Secrets
Only the URL and publishable key ship in the APK