Skip to content
Martin Mendoza edited this page May 22, 2025 · 4 revisions

🛡️ StateForce Documentation

🚀 Introduction

📌 What is StateForce?

StateForce is a state-level emergency resource management platform. It empowers public agencies to monitor, analyze, and optimize the availability and distribution of resources such as ambulances, rescue units, fire brigades, and hospital capacity in real time. The goal is to improve responsiveness and coordination during emergency situations.

🎯 Objectives

  • Maximize the operational efficiency of emergency response services.
  • Provide real-time visibility of resource status and location.
  • Support strategic planning and operational decision-making through actionable insights.

🔍 Scope

  • Included:

    • Registration and real-time tracking of emergency assets.
    • Live monitoring dashboard with location and operational views.
    • Resource utilization reporting and historical data export.
  • Excluded:

    • Direct dispatch or intervention in emergency operations.
    • Real-time communication with field units.

📋 Requirements

✅ Functional Requirements

  • Secure user authentication (email and Google OAuth).
  • Role-based access control (e.g. admin, guest).
  • Interactive dashboard for monitoring and reporting.
  • Monthly summaries and performance analytics.

⚙️ Non-Functional Requirements

  • Horizontal scalability to support multiple states and thousands of assets.
  • Real-time performance (sub-second latency for critical data).
  • Data security compliant with privacy and regulatory standards.

🧱 System Architecture

🧩 Stack Overview

  • Framework: Ruby on Rails (API + Views)
  • Database: PostgreSQL
  • Real-time: Hotwire (Turbo + Stimulus), Redis
  • Authentication: Devise + OmniAuth (Google)
  • Deployment: Heroku

📌 High-Level Diagram

User Flow


📊 Dashboard Preview

ChatGPT Image 19 may 2025, 11_06_36 a m


🗃️ Database Schema

Explore the full schema and relationships here: 🔗 Database Wiki Page


🤝 Collaboration Guidelines

💡 Best Practices

  • Follow Ruby Style Guide.
  • Use clear, descriptive commit messages.
  • Always write tests for new features and critical fixes.
  • Keep pull requests focused and well-documented.

📚 StateForce Wiki Sidebar

Welcome to the StateForce Wiki! Use this sidebar to navigate through the documentation.


🏠 Home


🛠 System Design


🗄 Database


🎨 Design & Style


🚦 User Workflows


🧪 Testing


📎 Others

This sidebar provides quick access to all the documentation pages. For detailed information, click on the desired section.

Clone this wiki locally