How warissecode/hopegestionv2 works
HopeGestionV2 is a web-based property-management product: managers and property owners maintain properties, tenants, leases and financial records, while tenants have role-specific access. The main workflow runs from the React application through backend API routes to PostgreSQL, with authentication and tenant protections shaping access. The README documents the broad client/server flow; sampled code confirms the app’s route protection, authentication-service calls and database access. Many feature routes are present in the tree but were not sampled, so their internal call wiring is not inferred.
Main entry points: database.ts PostgreSQL · App.tsx Web application · edlRoutes.ts Move-in/out inspections · LoginForm.tsx Login and signup
Components 23
Access and accounts
- Web application
frontend/src/App.tsx - Login and signup
frontend/src/components/LoginForm.tsx - Authentication API
backend/routes/authRoutes.ts - Authentication service
backend/services/AuthService.ts - Access middleware
backend/middleware/authMiddleware.ts - PostgreSQL
backend/db/database.ts
Property and tenancy
- Properties and lots
backend/routes/bienRoutes.ts - Tenant records
backend/routes/locataireRoutes.ts - Leases and rentals
backend/routes/leaseRoutes.ts - Reservations
backend/routes/reservationRoutes.ts - Move-in/out inspections
backend/routes/edlRoutes.ts
Payments and finance
- Rent payments
backend/routes/rentPaymentRoutes.ts - Receipts
backend/services/ReceiptService.ts - Finance and expenses
backend/routes/financeRoutes.ts - Mobile money
backend/services/mobileMoneyService.ts
Operations and insight
- Dashboard and reports
backend/services/DashboardService.ts - Documents and templates
backend/routes/documentRoutes.ts - Tasks and calendar
backend/routes/taskRoutes.ts - Alerts and notifications
backend/services/notificationService.ts - Audit history
backend/services/AuditService.ts - API server
backend/index.ts
Other components
- Manager / owner
- Tenant
Connections 23
- Manager / owner → Web application: uses
- Tenant → Web application: uses
- Web application → Login and signup: presents login
- Login and signup → Authentication API: submits credentials
- Authentication API → Authentication service: delegates auth
- Authentication service → PostgreSQL: reads and writes tokens
- Web application → API server: sends API requests
- API server → Access middleware: protects routes
- Properties and lots → PostgreSQL: reads and writes
- Tenant records → PostgreSQL: reads and writes
- Leases and rentals → PostgreSQL: reads and writes
- Reservations → PostgreSQL: reads and writes
- Move-in/out inspections → PostgreSQL: tenant-scoped queries
- Move-in/out inspections → Documents and templates: generates PDF
- Rent payments → PostgreSQL: reads and writes
- Receipts → PostgreSQL: accesses records
- Finance and expenses → PostgreSQL: reads and writes
- Mobile money → PostgreSQL: payment records
- Dashboard and reports → PostgreSQL: reads metrics
- Documents and templates → PostgreSQL: accesses records
- Tasks and calendar → PostgreSQL: accesses records
- Alerts and notifications → PostgreSQL: accesses records
- Audit history → PostgreSQL: accesses records