Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
309 changes: 248 additions & 61 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,40 +1,72 @@
# BC Cancer Fundation Donor Management System
# BC Cancer Foundation Donor Management System

A comprehensive event management system for handling donor events, donor management, and event-donor relationships.
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Node.js Version](https://img.shields.io/badge/node-%3E%3D18.0.0-brightgreen)](https://nodejs.org/)
[![React Version](https://img.shields.io/badge/react-18.2.0-blue)](https://reactjs.org/)
[![Build Status](https://github.com/PCBZ/CS5500-Project/workflows/CI/badge.svg)](https://github.com/PCBZ/CS5500-Project/actions/workflows/ci.yml)
[![GitHub issues](https://img.shields.io/github/issues/PCBZ/CS5500-Project)](https://github.com/PCBZ/CS5500-Project/issues)
[![GitHub forks](https://img.shields.io/github/forks/PCBZ/CS5500-Project)](https://github.com/PCBZ/CS5500-Project/network)
[![GitHub stars](https://img.shields.io/github/stars/PCBZ/CS5500-Project)](https://github.com/PCBZ/CS5500-Project/stargazers)
[![Version](https://img.shields.io/badge/version-1.0.0-blue)](https://github.com/PCBZ/CS5500-Project/releases)
[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://github.com/PCBZ/CS5500-Project/pulls)

A comprehensive donor management system designed specifically for BC Cancer Foundation to streamline event management, donor tracking, and relationship management for fundraising activities.

## Features

- Event Management
- Create and manage events
### 🎯 Core Functionality
- **Event Management**
- Create and manage fundraising events
- Track event status (Planning, List Generation, Review, Ready, Complete)
- Set event details (date, location, capacity, etc.)
- Export donor lists
- Real-time event status updates

- Donor Management
- Add and manage donors
- Track donor information and history
- Manage donor status for events
- Export donor data
- Advanced search and filtering
- Set comprehensive event details (date, location, capacity, focus area)
- Export donor lists in multiple formats
- Real-time event status updates and timeline management

- **Donor Management**
- Comprehensive donor database with detailed profiles
- Track donation history and giving patterns
- Manage donor status for specific events (Approved, Excluded, Pending)
- Advanced search and filtering capabilities
- Export donor data for external use

### πŸ“Š Analytics & Reporting
- Real-time dashboard with key metrics
- Donor list statistics and approval rates
- Event performance tracking
- Progress monitoring and reporting tools

### πŸ” Security & Authentication
- Secure JWT-based authentication system
- Role-based access control
- Protected API endpoints
- User session management

## Tech Stack

- Frontend:
- React.js
- Redux for state management
- React Router for navigation

- Backend:
- Node.js with Express
- MySQL for database
- JWT for authentication
- Jest for testing

- DevOps:
- Docker for containerization
- GitHub Actions for CI/CD
- ESLint for code formatting
### Frontend
- **React.js** (v18.2.0) - Modern UI library with hooks and functional components
- **TypeScript** - Type-safe JavaScript for better development experience
- **React Router** (v6) - Client-side routing and navigation
- **React Icons** - Comprehensive icon library

### Backend
- **Node.js** (v18+) - JavaScript runtime environment
- **Express.js** - Web application framework
- **Prisma ORM** - Type-safe database client and migrations
- **MySQL** (v8.0+) - Relational database management system
- **JWT** - JSON Web Tokens for authentication
- **bcrypt** - Password hashing and security

### Testing & Quality
- **Jest** - JavaScript testing framework
- **React Testing Library** - Testing utilities for React components
- **ESLint** - Code linting and quality enforcement
- **Prettier** - Code formatting and style consistency

### DevOps & Deployment
- **Docker** - Containerization for consistent deployments
- **GitHub Actions** - CI/CD pipeline automation
- **Render/Heroku** - Cloud deployment platforms

## Prerequisites

Expand All @@ -45,34 +77,78 @@ A comprehensive event management system for handling donor events, donor managem

## Installation

1. Clone the repository:
### Quick Start

1. **Clone the repository:**
```bash
git clone git@github.com:PCBZ/CS5500-Project.git
cd CS5500-Project
```

2. **Install all dependencies:**
```bash
npm run install:all
```

3. **Set up environment variables:**

**Backend (.env in Server directory):**
```bash
cd Server
cp .env.example .env
```
Configure the following variables:
```env
DATABASE_URL="mysql://username:password@localhost:3306/donor_management"
JWT_SECRET="your_secure_jwt_secret_key"
PORT=5000
NODE_ENV=development
```

**Frontend (.env in client directory):**
```bash
cd ../client
cp .env.example .env
```
Configure:
```env
REACT_APP_API_URL=http://localhost:5000
```

4. **Set up the database:**
```bash
cd ../Server
npx prisma generate
npx prisma migrate dev
```

5. **Start the development servers:**
```bash
# Option 1: Start both frontend and backend together (recommended)
npm start

# Option 2: Start separately
# Backend (from Server directory)
cd Server && npm run dev

# Frontend (from client directory, in a new terminal)
cd client && npm start
```

6. **Access the application:**
- Frontend: http://localhost:3000
- Backend API: http://localhost:5000

### Alternative Installation Methods

#### Using Docker
```bash
git clone git@github.com:PCBZ/CS5500-Project.git
cd CS5500-Project
docker-compose up -d
```

2. Install dependencies:
#### Production Build
```bash
# Install backend dependencies
cd Server
npm install

# Install frontend dependencies
cd ../client
npm install
```

3. Set up environment variables:
- Copy `.env.example` to `.env` in both Server and client directories
- Update the variables with your configuration

4. Start the development servers:
```bash
# Start backend server (from Server directory)
npm run dev

# Start frontend server (from client directory)
npm start
npm run start:prod
```

## Project Structure
Expand Down Expand Up @@ -109,18 +185,39 @@ npm start

## Testing

### Backend Tests
### Running Tests

#### Backend Tests
```bash
cd Server
npm test
```

### Frontend Tests
#### Frontend Tests
```bash
cd client
npm test
```

#### Run All Tests
```bash
# From root directory
npm test
```

### Test Coverage
- **Backend**: Unit tests for API endpoints, authentication, and database operations
- **Frontend**: Component tests, integration tests, and user interaction tests
- **E2E Testing**: Automated testing of complete user workflows

### Continuous Integration
All tests are automatically run on:
- Every push to main branch
- All pull requests
- Manual workflow dispatch

View test results: [GitHub Actions](https://github.com/PCBZ/CS5500-Project/actions)

## Deployment

### Docker Deployment
Expand Down Expand Up @@ -150,12 +247,102 @@ Configure the application using environment variables:

## Contributing

1. Fork the repository
2. Create your feature branch (`git checkout -b feature/amazing-feature`)
3. Commit your changes (`git commit -m 'Add some amazing feature'`)
4. Push to the branch (`git push origin feature/amazing-feature`)
5. Open a Pull Request
We welcome contributions to the BC Cancer Foundation Donor Management System! Please read our contribution guidelines below.

### How to Contribute

1. **Fork the repository**
```bash
# Click the "Fork" button on GitHub or use GitHub CLI
gh repo fork PCBZ/CS5500-Project
```

2. **Create your feature branch**
```bash
git checkout -b feature/amazing-feature
```

3. **Make your changes**
- Follow the existing code style and conventions
- Add tests for new functionality
- Update documentation as needed

4. **Run tests and linting**
```bash
# Run all tests
npm test

# Run linting
cd client && npm run lint
cd ../Server && npm run lint
```

5. **Commit your changes**
```bash
git commit -m 'Add some amazing feature'
```

6. **Push to your branch**
```bash
git push origin feature/amazing-feature
```

7. **Open a Pull Request**
- Use the GitHub web interface or GitHub CLI
- Provide a clear description of your changes
- Reference any related issues

### Development Guidelines

- **Code Style**: Follow ESLint and Prettier configurations
- **Testing**: Maintain or improve test coverage
- **Documentation**: Update README and inline documentation
- **Commit Messages**: Use clear, descriptive commit messages
- **Pull Requests**: Keep PRs focused and atomic

### Reporting Issues

If you encounter bugs or have feature requests:
1. Check existing [issues](https://github.com/PCBZ/CS5500-Project/issues)
2. Create a new issue with detailed description
3. Include steps to reproduce (for bugs)
4. Add relevant labels and milestones

### Code of Conduct

This project adheres to a code of conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to the maintainers.

## License

This project is licensed under the MIT License - see the LICENSE file for details.
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

### License Summary
- βœ… Commercial use
- βœ… Modification
- βœ… Distribution
- βœ… Private use
- ❌ Liability
- ❌ Warranty

## Contact & Support

### Maintainers
- **Project Team**: PCBZ Organization
- **Repository**: [PCBZ/CS5500-Project](https://github.com/PCBZ/CS5500-Project)

### Getting Help
- πŸ“‹ **Issues**: [GitHub Issues](https://github.com/PCBZ/CS5500-Project/issues)
- πŸ”€ **Pull Requests**: [GitHub PRs](https://github.com/PCBZ/CS5500-Project/pulls)
- πŸ“– **Documentation**: Check the [docs](Server/docs/) directory for API documentation

### Project Links
- 🏠 **Homepage**: [GitHub Repository](https://github.com/PCBZ/CS5500-Project)
- πŸ“ˆ **Actions**: [CI/CD Pipeline](https://github.com/PCBZ/CS5500-Project/actions)
- πŸ› **Bug Reports**: [New Issue](https://github.com/PCBZ/CS5500-Project/issues/new)

---

<div align="center">
<p>Built with ❀️ for BC Cancer Foundation</p>
<p>Made by <a href="https://github.com/PCBZ">PCBZ Team</a></p>
</div>
Loading