A web application for managing elementary school chess clubs, designed to streamline attendance tracking, tournament organization, and student registration.
-
Attendance Management
- Digital check-in/check-out system
- Real-time attendance tracking with live updates
- Self-release approval tracking
- Historical session viewing
- Pacific Time (PT) synchronization
- Automated session creation
- Weekly attendance statistics
- Configurable automatic reset schedules
-
Tournament System
- Match recording and results tracking
- Grade-based rankings
- Overall tournament standings
- Real-time tournament standings
- Material difference tracking
- Match history with detailed results
- Achievement tracking system including:
- "5 Point Club"
- "10 Point Master"
- "Social Player" (5+ unique opponents)
- "Chess Ambassador" (10+ unique opponents)
- "Active Player" (10+ games)
- "Chess Champion" (70%+ win rate with 5+ games)
-
Student Management
- Digital registration system with validation
- Comprehensive student directory
- Multi-contact support for guardians
- Self-release permission management
- Contact information management
- Student notes and history tracking
- Active/inactive status management
- Grade and teacher filtering
- Real-time student updates
-
Administrative Features
- Secure admin dashboard
- Session management tools
- Historical data access
- Database reset controls
- Student data purging tools
- Tournament data reset capability
- Automated cleanup scheduling
- Real-time synchronization status
- Pacific Time enforcement
- Node.js >= 18.0.0
- npm >= 8.0.0
- A Supabase account (free tier works fine)
- A Vercel account (free tier works fine)
- Git installed on your local machine
The application now includes:
-
Self-Release Management
- Toggle self-release permissions
- Track self-release checkouts
- Permission inheritance
- Real-time permission updates
-
Historical Session Access
- View past session data
- Attendance history tracking
- Session statistics
- Non-modifiable historical records
-
Real-Time Updates
- Live attendance tracking
- Instant permission changes
- Connection status monitoring
- Automatic data synchronization
-
Time Management
- Pacific Time enforcement
- Automated session creation
- Time-based validations
- Session schedule tracking
-
Create a new Supabase project at supabase.com
-
In your Supabase dashboard, go to the SQL Editor
-
Create a new query and paste the complete SQL setup script (available in
supabase/init.sql
)- This script will:
- Create all necessary tables with proper constraints
- Set up indexes for performance optimization
- Enable Row Level Security (RLS)
- Create security policies
- Set up triggers for timestamp management
- Create useful views for statistics
- Initialize reset management system
- Set up audit logging
- This script will:
-
Configure Authentication:
- Go to Authentication > Settings
- Enable Email provider
- Disable Email confirmations for development (optional)
- Set up any additional auth providers as needed
-
Get Your API Keys:
- Go to Project Settings > API
- Copy the
anon
public key and URL - Add these to your
.env
file:VITE_SUPABASE_URL=your_project_url VITE_SUPABASE_ANON_KEY=your_anon_key
-
Set up Tables:
- Students table (personal and contact info)
- Attendance sessions and records
- Tournament matches and results
- System configuration
- Reset audit logs
-
Verify Setup:
- Run the test queries provided in the verification section
- Check table structures and relationships
- Verify RLS policies are active
- Test authentication flows
-
Configure Reset Management:
- System includes automatic and manual reset capabilities
- Configure through admin interface
- Set up scheduled resets if needed
- Test reset functionality with sample data
The application includes sophisticated data management features:
-
Automated Reset Scheduling
- Schedule automatic resets for attendance data
- Configure specific days and times for resets
- All times are handled in Pacific Time (PT)
- Track last reset timestamp
- Email notifications for scheduled resets
-
Manual Reset Options
- Tournament data reset with verification
- Current session reset capability
- Protected by math verification challenge
- Audit trail of reset operations
-
Safety Features
- Two-step verification for critical operations
- Math challenge verification
- Confirmation dialogs
- Detailed logging of reset operations
- Timezone-aware scheduling
- Fork and Clone:
git clone [your-fork-url]
cd chess-club
- Install Dependencies:
npm install
- Environment Setup:
# Create .env file
cp .env.example .env
# Update with your values
VITE_SUPABASE_URL=your_project_url
VITE_SUPABASE_ANON_KEY=your_anon_key
- Local Development:
# Start development server
npm run dev
# Build for production
npm run build
# Preview production build
npm run preview
- Vercel Setup:
# Install Vercel CLI
npm i -g vercel
# Login to Vercel
vercel login
# Deploy
vercel
- Environment Variables:
- Set up in Vercel dashboard:
- VITE_SUPABASE_URL
- VITE_SUPABASE_ANON_KEY
- Enable preview branches if needed
- Configure custom domain (optional)
- Set up in Vercel dashboard:
- Comprehensive authentication using Supabase Auth
- Row Level Security (RLS) policies on all tables
- Protected reset operations with verification
- Audit logging for critical operations
- Secure session management
- Environmental variable protection
- Regular automated backups
- Rate limiting on API endpoints
-
Regular Tasks:
- Monitor scheduled resets
- Review audit logs
- Backup database
- Update dependencies
- Check error logs
-
Seasonal Tasks:
- Archive old tournament data
- Update student roster
- Review system configurations
- Update teacher lists
- Fork the repository
- Create a feature branch
- Make your changes
- Submit a pull request
Contribution Guidelines:
- Follow existing code style
- Add tests for new features
- Update documentation
- Test thoroughly
src/
├── components/ # React components
│ ├── attendance/ # Attendance tracking
│ ├── tournaments/ # Tournament management
│ ├── students/ # Student management
│ └── shared/ # Shared components
├── hooks/ # Custom React hooks
├── lib/ # Utility functions
├── pages/ # Route pages
└── styles/ # Global styles
MIT License - See LICENSE file for details
For support:
- Check documentation
- Review common issues
- Open GitHub issue
- Contact maintainers
- React + Vite for framework
- Supabase for backend
- Vercel for hosting
- TailwindCSS for styling
- Contributors and maintainers