Mobile App for Work Time Tracking
Excel timesheet and manual check marks in journal — not just inconvenient, but constant source of disputes between HR and employees. "I came at 9:02, but you have 9:15" — no way to prove. Mobile app with geotagged check-ins solves this, but only if implemented correctly: can't check in from home, proper offline work, reports go directly to accounting.
Check-In/Out: Technical Honesty
Geofencing — fraud prevention foundation. On check-in, app verifies user is within N meters of workplace. iOS: CLLocationManager with requestLocation() (single measurement, saves battery) — accuracy kCLLocationAccuracyNearestTenMeters. Android: FusedLocationProviderClient.getCurrentLocation(PRIORITY_HIGH_ACCURACY) from Google Location Services.
Geozones built on client (distance check via CLLocation.distance(from:)) or server (PostGIS ST_DWithin). Server check more reliable — client code can be faked. Coordinates on check-in sent to API, server verifies via PostGIS and returns status.
Secondary problem — GPS accuracy indoors. On first floor of business center, error can reach 50-100 meters. Solution: GPS + Wi-Fi fingerprinting combination. On check-in, save list of visible Wi-Fi points (BSSID + RSSI) via NEHotspotHelper (iOS, requires entitlement) or WifiManager.getScanResults() (Android). If GPS inaccurate — compare with office reference fingerprint.
For strict control — NFC tags at entrance. Employee taps phone to tag, app reads NFCNDEFReaderSession (iOS) or NfcAdapter (Android) and auto-fixes check-in with timestamp. Impossible to fake physically.
Offline Mode and Sync
Construction site, warehouse, field teams — internet unstable. All check-ins save locally and sync on network availability.
Local storage: SQLite via Room (Android) or GRDB.swift (iOS). time_records table: id (UUID, generated locally), type (check_in/check_out/break_start/break_end), latitude, longitude, wifi_bssids, timestamp, synced (boolean), sync_error.
Background sync: iOS — BGTaskScheduler with BGAppRefreshTask. Android — WorkManager with NetworkType.CONNECTED. On sync — batch upload all unsynced records, server ensures idempotency by client_id.
Important: if employee forgot to check in — manual correction option with mandatory comment and manager notification (push via FCM/APNs).
Timesheet and Reports
Timesheet — summary table for period. Per employee: date, arrival time, departure time, breaks, total hours, status (on-time/late/overtime). Generated on backend, client receives paginated JSON.
Export: PDF via WeasyPrint/Puppeteer on server or Excel via xlsxwriter (Python) / Apache POI (Java). Client downloads file via URL with short-lived signed token. iOS — UIDocumentInteractionController for open/share. Android — FileProvider + Intent.ACTION_VIEW.
Integration with 1C: 1C accepts data via REST API (HTTP service) or file exchange (CSV/XML by schedule). For direct integration, need 1C developer on client side — we prepare API with needed data structure.
Roles and Structure
Three levels: employee (sees own timesheet, makes check-ins), supervisor (sees department timesheet, approves corrections), HR/accounting (full access, export, schedule settings). Authorization — JWT with role in payload, middleware-level API check.
Work schedule (shift, flexible, standard 9-18) set in admin — mobile app accounts for it on calculating lates and overtimes.
Timeline
Basic app (GPS check-in/out, timesheet, export) — 2-4 weeks. With NFC, Wi-Fi fingerprinting, offline mode, and 1C integration — 6-10 weeks. Cost individual: platforms count, need web version for HR, integration volume with external systems.







