How jshmlnd/ust-legazpi-mhss works
This is a semi-anonymous university counseling and wellbeing application for students, counselors, and administrators. Users authenticate and enter role-specific experiences; students can find resources, use self-care and diary features, request counseling, and communicate with counselors through messaging and voice sessions. Counselors manage appointments, availability, and announcements, while administrators register users. The graph combines documented capabilities with sampled routing, API, persistence, and socket evidence; several feature-to-backend connections are dashed because their implementation was not sampled.
Main entry points: App.jsx Role-based app · socket.js Realtime sessions · appointment.controller.js Appointment handling · useChatStore.js Chat state
Components 29
Application entry
- Role-based app
frontend/src/App.jsx
Identity and access
- Authentication UI
frontend/src/pages/LoginPage.jsx - Auth state
frontend/src/store/useAuthStore.js - Authentication API
backend/src/controllers/auth.controller.js - User and counselor records
backend/src/models/user.model.js
Counseling services
- Session booking
frontend/src/pages/SessionsPage.jsx - Appointment handling
backend/src/controllers/appointment.controller.js - Appointment records
backend/src/models/appointment.model.js - Chat experience
frontend/src/pages/ChatPage.jsx - Chat state
frontend/src/store/useChatStore.js - Message handling
backend/src/controllers/message.controller.js - Messages
backend/src/models/message.model.js - Realtime sessions
backend/src/socket/socket.js - Voice calls
frontend/src/components/VoiceCallModal.jsx
Wellbeing and resources
- Mood diary
frontend/src/pages/YourDiary.jsx - Self-care library
frontend/src/pages/SelfCarePage.jsx - Resource mapping
frontend/src/pages/ResourcePage.jsx - Resource handling
backend/src/controllers/resource.controller.js - Resource records
backend/src/models/resource.model.js
Campus operations
- Announcements
frontend/src/pages/CounselorAnnouncementManagerPage.jsx - Announcement handling
backend/src/controllers/announcement.controller.js - Announcement records
backend/src/models/announcement.model.js - Counselor availability
backend/src/controllers/availability.controller.js - Session reminders
backend/src/lib/reminders.js - Help desk
frontend/src/pages/SuggestionsPage.jsx - Administration
frontend/src/pages/Administrator.jsx
Other components
- Student
- Counselor
- Administrator
Connections 31
- Student → Role-based app: uses
frontend/src/App.jsx - Counselor → Role-based app: uses
frontend/src/App.jsx - Administrator → Role-based app: uses
frontend/src/App.jsx - Role-based app → Authentication UI: routes to
frontend/src/App.jsx - Authentication UI → Auth state: submits credentials
- Auth state → Authentication API: posts login
frontend/src/store/useAuthStore.js - Authentication API → User and counselor records: checks accounts
backend/src/controllers/auth.controller.js - Role-based app → Session booking: routes to
frontend/src/App.jsx - Session booking → Appointment handling: requests sessions
- Appointment handling → Appointment records: reads and writes
backend/src/controllers/appointment.controller.js - Appointment handling → Realtime sessions: emits updates
backend/src/controllers/appointment.controller.js - Role-based app → Chat experience: routes to
frontend/src/App.jsx - Chat experience → Chat state: uses state
- Chat state → Message handling: posts messages
frontend/src/store/useChatStore.js - Message handling → Messages: reads and writes
backend/src/controllers/message.controller.js - Chat state → Realtime sessions: emits events
frontend/src/store/useChatStore.js - Role-based app → Realtime sessions: connects socket
- Role-based app → Voice calls: shows call UI
frontend/src/App.jsx - Voice calls → Realtime sessions: coordinates calls
- Role-based app → Mood diary: routes to
frontend/src/App.jsx - Role-based app → Self-care library: routes to
frontend/src/App.jsx - Role-based app → Resource mapping: routes to
frontend/src/App.jsx - Resource mapping → Resource handling: manages resources
- Resource handling → Resource records: reads and writes
backend/src/controllers/resource.controller.js - Counselor → Announcements: manages updates
- Announcements → Announcement handling: sends requests
frontend/src/pages/CounselorAnnouncementManagerPage.jsx - Announcement handling → Announcement records: reads and writes
backend/src/controllers/announcement.controller.js - Counselor → Counselor availability: sets availability
- Session reminders → Appointment records: checks sessions
- Role-based app → Help desk: routes to
frontend/src/App.jsx - Administrator → Administration: registers users