A comprehensive web application for managing society/apartment complex operations including member management, maintenance requests, visitor tracking, events, financial management, and more.
Society_Management-1/
βββ client/society-management/ # React frontend application
β βββ src/
β β βββ admin/ # Admin dashboard components
β β βββ components/ # Reusable components
β β βββ contexts/ # React contexts (Auth, etc.)
β β βββ hooks/ # Custom React hooks
β β βββ pages/ # Page components
β β βββ services/ # API service layer
β β βββ ...
β βββ package.json
β βββ vite.config.js
βββ server/ # Node.js/Express backend
β βββ controllers/ # Route controllers
β βββ models/ # MongoDB models
β βββ routes/ # API routes
β βββ middlewares/ # Custom middlewares
β βββ utils/ # Utility functions
β βββ logs/ # Application logs
β βββ scripts/ # Database scripts
βββ README.md
- Member Management: Add, edit, view member details with comprehensive information
- Building Management: Manage buildings, maintenance schedules, and amenities
- Financial Management: Track income, expenses, and generate financial reports
- Maintenance & Rent: Handle maintenance requests and rent collections
- Visitor Management: Track visitor entries and exits with security features
- Event Management: Organize events, manage registrations and feedback
- Complaints & Feedback: Handle resident complaints with ticketing system
- Notices & Communication: Broadcast notices and important communications
- Health Records: Maintain health records for emergency situations
- Services: Manage various services offered to residents
- Staff Management: Handle support staff information and schedules
- Reports & Analytics: Generate comprehensive reports and insights
- JWT-based authentication
- Role-based access control (Admin, Watchman, Member)
- Password encryption using bcrypt
- Protected routes and API endpoints
- Members: Complete member information with emergency contacts
- Buildings: Building details with maintenance schedules
- Transactions: Financial transaction tracking
- Events: Event management with registration and feedback
- Complaints: Ticketing system for complaints with timeline
- Notices: Notice board with read/acknowledgment tracking
- Health Records: Medical information and emergency contacts
- Services: Service booking and management
- Visitors: Visitor tracking with check-in/out
- Support Staff: Staff management and attendance
- React 19.1.0 - UI library
- Vite - Build tool and dev server
- React Router DOM - Client-side routing
- Tailwind CSS - Utility-first CSS framework
- Framer Motion - Animation library
- Lucide React - Icon library
- Node.js - Runtime environment
- Express.js - Web framework
- MongoDB - Database
- Mongoose - ODM for MongoDB
- JWT - Authentication
- bcrypt - Password hashing
- Winston - Logging
- Helmet - Security headers
- CORS - Cross-origin resource sharing
- Node.js (v16 or higher)
- MongoDB (local or cloud instance)
- npm or yarn package manager
- Navigate to the server directory:
cd server- Install dependencies:
npm install- Configure environment variables:
# Copy the .env file and update with your values
cp .env.example .env- Update
.envfile with your configuration:
PORT=5000
MONGODB_URI=mongodb://localhost:27017/society-management
JWT_SECRET=your-super-secret-jwt-key
JWT_EXPIRE=7d
FRONTEND_URL=http://localhost:3000
- Start the server:
# Development mode
npm run dev
# Production mode
npm start- Navigate to the client directory:
cd client/society-management- Install dependencies:
npm install- Configure environment variables:
# Create .env file
touch .env- Add environment variables to
.env:
VITE_API_URL=http://localhost:5000/api
VITE_APP_NAME=Society Management System
- Start the development server:
npm run devPOST /api/auth/login- User loginPOST /api/auth/logout- User logoutPOST /api/auth/forgot-password- Forgot passwordPOST /api/auth/reset-password- Reset password
GET /api/members- Get all membersGET /api/members/:id- Get member by IDPOST /api/members- Create new memberPUT /api/members/:id- Update memberDELETE /api/members/:id- Delete member
GET /api/buildings- Get all buildingsPOST /api/buildings- Create new buildingPUT /api/buildings/:id- Update buildingGET /api/buildings/statistics- Get building statistics
GET /api/accounts/transactions- Get all transactionsPOST /api/accounts/transactions- Create new transactionPUT /api/accounts/transactions/:id- Update transactionGET /api/accounts/summary- Get financial summary
GET /api/events- Get all eventsPOST /api/events- Create new eventPOST /api/events/:id/register- Register for eventPOST /api/events/:id/feedback- Add event feedback
GET /api/complaints- Get all complaintsPOST /api/complaints- Create new complaintPUT /api/complaints/:id- Update complaint statusPOST /api/complaints/:id/feedback- Add complaint feedback
GET /api/notices- Get all noticesPOST /api/notices- Create new noticePOST /api/notices/:id/read- Mark notice as readPOST /api/notices/:id/acknowledge- Acknowledge notice
GET /api/health- Get health recordsPOST /api/health- Create health recordGET /api/health/member/:memberId- Get member's health records
GET /api/services- Get all servicesPOST /api/services- Create new servicePOST /api/services/:id/book- Book servicePOST /api/services/:id/bookings/:bookingId/feedback- Add service feedback
GET /api/maintenance/requests- Get maintenance requestsPOST /api/maintenance/requests- Create maintenance requestPUT /api/maintenance/requests/:id- Update maintenance request
GET /api/visitors- Get all visitorsPOST /api/visitors- Register new visitorPOST /api/visitors/:id/checkin- Check in visitorPOST /api/visitors/:id/checkout- Check out visitor
- users - User authentication and basic info
- memberlist - Detailed member information
- buildings - Building and property information
- transactions - Financial transactions
- events - Event management
- complaints - Complaint tracking
- notices - Notice board
- healthrecords - Health and medical records
- services - Service management
- visitors - Visitor tracking
- JWT Authentication: Secure token-based authentication
- Role-based Access Control: Different permissions for Admin, Watchman, and Member roles
- Password Encryption: bcrypt hashing for secure password storage
- Input Validation: Mongoose schema validation and custom validation
- CORS Configuration: Controlled cross-origin requests
- Helmet Integration: Security headers for Express
- Rate Limiting: API rate limiting to prevent abuse
The application uses Winston for comprehensive logging:
- Error Logs:
logs/error.log - Combined Logs:
logs/combined.log - Console Output: Development mode console logging
# Run backend tests
cd server
npm test
# Run frontend tests
cd client/society-management
npm test- Set environment variables for production
- Build and deploy to your preferred platform (Heroku, DigitalOcean, AWS, etc.)
- Ensure MongoDB is accessible from production environment
- Build the production bundle:
npm run build- Deploy the
distfolder to your static hosting service (Netlify, Vercel, etc.) - Update API URLs for production environment
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Edge (latest)
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
For support and questions, please create an issue in the GitHub repository or contact the development team.
- v1.0.0 - Initial release with core features
- Member management
- Building management
- Financial tracking
- Event management
- Complaint system
- Notice board
- Visitor management
- Health records
- Service management
- Mobile application (React Native)
- Email notification system
- SMS integration
- Payment gateway integration
- Advanced reporting dashboard
- Mobile-responsive design improvements
- Real-time notifications
- Document management system
- Integration with accounting software