How kyox7485/osem-webapp works
This is a Next.js care-management application for residential-care staff. The broad workflow is staff authentication and branch-scoped work, followed by resident, clinical, medication, physiotherapy, or inventory tasks and, where needed, generated reports. The tree shows substantial capabilities across these areas, but the README is empty and most feature pages were not sampled; those branches are represented without asserting unverified call chains. Edges are limited to relationships visible in excerpts or the source index.
Main entry points: layout.tsx Authenticated app shell · reports PDF report endpoints · server.ts Inventory server services · page.tsx Medication management
Components 24
Application shell
- Authenticated app shell
webapp/src/app/(app)/layout.tsx - Accounts and staff
webapp/src/app/(app)/accounts/page.tsx
Resident care
- Resident records
webapp/src/app/(app)/residents/[id]/page.tsx - Medication management
webapp/src/app/(app)/residents/medication/orders/page.tsx - Medication stock logic
webapp/src/lib/medication-stock.ts - Medication chart calendar
webapp/src/lib/medication-chart/calendar-engine.ts - Resident consumables
webapp/src/app/(app)/residents/consumables/page.tsx
Clinical practice
- Clinical records
webapp/src/app/(app)/clinical/page.tsx - Wound photo upload
webapp/src/app/api/wound-photos/route.ts - Physiotherapy assessments
webapp/src/app/(app)/physiotherapy/assessment-review.tsx - Callbell alerts
webapp/src/app/(app)/callbell/page.tsx
Inventory operations
- Inventory workflows
webapp/src/app/(app)/inventory/page.tsx - Inventory server services
webapp/src/lib/inventory/server.ts - Inventory rules and types
webapp/src/lib/inventory/core.ts
Data and reporting
- Supabase data service
webapp/src/lib/supabase/server.ts - Google Drive
- PDF report endpoints
webapp/src/app/api/reports - Resident PDF document
webapp/src/lib/pdf/documents/resident-document.tsx - Nursing chart PDF
webapp/src/lib/pdf/documents/nursing-chart-document.tsx - Physio assessment PDF
webapp/src/lib/pdf/documents/physio-assessment-document.tsx - Purchase list PDF
webapp/src/lib/pdf/documents/purchase-list-document.tsx - Translation services
webapp/src/lib/i18n/server.ts - Translation engine
webapp/src/lib/i18n/translate.ts
Other components
- Care staff
Connections 17
- Care staff → Authenticated app shell: uses
- Authenticated app shell → Resident records: opens
- Authenticated app shell → Clinical records: opens
- Authenticated app shell → Inventory workflows: opens
- Authenticated app shell → Accounts and staff: opens
- Medication management → Medication stock logic: uses
- Medication management → Medication chart calendar: uses
- Inventory workflows → Inventory server services: loads services
- Inventory server services → Inventory rules and types: imports rules
webapp/src/lib/inventory/server.ts - Inventory server services → Supabase data service: queries data
webapp/src/lib/inventory/server.ts - Wound photo upload → Supabase data service: reads and writes
webapp/src/app/api/wound-photos/route.ts - Wound photo upload → Google Drive: uploads photo
webapp/src/app/api/wound-photos/route.ts - PDF report endpoints → Resident PDF document: renders
webapp/src/app/api/reports/resident/route.tsx - PDF report endpoints → Nursing chart PDF: renders
webapp/src/app/api/reports/nursing-chart/route.tsx - PDF report endpoints → Physio assessment PDF: renders
webapp/src/app/api/reports/physio-assessment/route.tsx - PDF report endpoints → Purchase list PDF: renders
webapp/src/app/api/reports/purchase-list/route.tsx - Translation services → Translation engine: calls
webapp/src/lib/i18n/server.ts