Skip to content

boilerrat/RadRoster

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

RadRoster - Radiation Dose Tracking App

A safety-critical mobile application for nuclear industry supervisors and RPOs to track radiation doses, manage workers, and ensure regulatory compliance.

πŸš€ Day 1 Setup Complete

What's Been Implemented

Backend (Node.js + Express)

  • βœ… Express server with TypeScript
  • βœ… JWT authentication with refresh tokens
  • βœ… PostgreSQL database configuration with Sequelize
  • βœ… Comprehensive error handling and logging
  • βœ… Health check endpoints
  • βœ… Security middleware (helmet, CORS, rate limiting)
  • βœ… Environment variable configuration
  • βœ… ESLint and Jest setup

Mobile App (React Native)

  • βœ… React Native scaffold with TypeScript
  • βœ… Navigation setup with React Navigation
  • βœ… Authentication context and hooks
  • βœ… Network and sync context providers
  • βœ… Basic screen structure (Login, Dashboard, Dose Entry, etc.)
  • βœ… API service configuration
  • βœ… Offline-first architecture foundation

CI/CD & Infrastructure

  • βœ… GitHub Actions workflow for lint/test/build
  • βœ… Monorepo structure with workspaces
  • βœ… Environment variable templates
  • βœ… Comprehensive testing setup

πŸ—οΈ Project Structure

RadRoster/
β”œβ”€β”€ backend/                 # Node.js + Express API
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ config/         # Database, API config
β”‚   β”‚   β”œβ”€β”€ middleware/     # Auth, error handling
β”‚   β”‚   β”œβ”€β”€ routes/         # API endpoints
β”‚   β”‚   β”œβ”€β”€ services/       # Business logic
β”‚   β”‚   β”œβ”€β”€ utils/          # Utilities and logging
β”‚   β”‚   └── test/           # Test setup
β”‚   └── package.json
β”œβ”€β”€ mobile-app/             # React Native app
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ components/     # Reusable components
β”‚   β”‚   β”œβ”€β”€ contexts/       # React contexts
β”‚   β”‚   β”œβ”€β”€ hooks/          # Custom hooks
β”‚   β”‚   β”œβ”€β”€ screens/        # App screens
β”‚   β”‚   β”œβ”€β”€ services/       # API services
β”‚   β”‚   └── config/         # App configuration
β”‚   └── package.json
β”œβ”€β”€ .github/workflows/      # CI/CD pipelines
β”œβ”€β”€ env.sample              # Environment variables template
└── README.md

πŸš€ Quick Start

Prerequisites

  • Node.js 18+
  • PostgreSQL 15+
  • React Native development environment
  • Git

Backend Setup

  1. Install dependencies:

    cd backend
    npm install
  2. Configure environment:

    cp ../env.sample .env
    # Edit .env with your database and API credentials
  3. Start development server:

    npm run dev
  4. Run tests:

    npm test

Mobile App Setup

  1. Install dependencies:

    cd mobile-app
    npm install
  2. iOS setup (macOS only):

    cd ios && pod install
  3. Start Metro bundler:

    npm start
  4. Run on device/simulator:

    # iOS
    npm run ios
    
    # Android
    npm run android

πŸ” Authentication

The app uses JWT tokens with refresh token rotation:

  • Access Token: 15 minutes
  • Refresh Token: 7 days
  • Demo Credentials:
    • Email: admin@radroster.com
    • Password: admin123

πŸ§ͺ Testing

Backend Tests

cd backend
npm test              # Run all tests
npm run test:watch    # Watch mode
npm run test:coverage # Coverage report

Mobile App Tests

cd mobile-app
npm test              # Run all tests

πŸ“± Features (Planned)

Day 1 βœ…

  • Authentication system
  • Basic app structure
  • CI/CD pipeline
  • Environment configuration

Day 2 (Next)

  • Database models (Worker, Job, DoseEntry)
  • CRUD operations
  • React Native forms

Day 3

  • Dose entry and extrapolation
  • Forecasting algorithms

Day 4

  • Dashboard with charts
  • Dose summaries

Day 5

  • Alert system
  • Push notifications

Day 6

  • Training records
  • Compliance reporting

Day 7

  • Offline sync
  • End-to-end testing

πŸ”§ Development

Code Standards

  • TypeScript: Strict mode enabled
  • ESLint: Airbnb config with TypeScript
  • Prettier: Code formatting
  • Jest: Unit and integration testing

Safety & Compliance

  • All dose calculations validated
  • Comprehensive error handling
  • Audit trail logging
  • Nuclear industry security standards

Offline-First

  • SQLite local storage
  • Conflict resolution
  • Sync status indicators
  • Graceful network failure handling

πŸ“Š API Endpoints

Authentication

  • POST /api/auth/login - User login
  • POST /api/auth/refresh - Refresh token
  • POST /api/auth/logout - User logout
  • GET /api/auth/me - Current user

Health

  • GET /health - Basic health check
  • GET /health/detailed - Detailed health with DB

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests
  5. Submit a pull request

πŸ“„ License

This project is proprietary software for nuclear industry use.

πŸ†˜ Support

For technical support or questions about the radiation dose tracking system, please contact the development team.


⚠️ Safety Notice: This is a safety-critical application for nuclear industry use. All dose calculations and data handling must be thoroughly tested and validated before production deployment.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors