A comprehensive web-based vehicle request and approval management system designed for armed forces personnel.
AMVRS ARMED is a robust vehicle management system built for armed forces operations. It enables personnel to request vehicles, track request status, and provides administrators with management tools for approvals and vehicle inventory.
git clone https://github.com/ajiko2505/Works.git
cd Works
# Using MySQL command line
mysql -u root -p < database/amvrss.sql
# Or manually:
# - Open phpMyAdmin
# - Create database: amvrss
# - Import: database/amvrss.sql
# Copy environment template
cp .env.example .env
# Edit .env with your settings
# - Database credentials
# - SMTP settings for email
# - Admin email address
composer install
http://localhost/WorksWorks/
├── assets/
│ └── css/
│ ├── global_styles.css
│ ├── modern_ui.css # Modern design system
│ ├── header_style.css
│ └── register_style.css
├── database/
│ └── amvrss.sql # Database schema
├── tests/
│ ├── bootstrap.php # PHPUnit setup
│ └── HelpersTest.php # Unit tests
├── PHPmailer/ # Email library
├── logs/ # Error & audit logs
├── .github/workflows/ # CI/CD pipelines
│
├── Core Files
├── index.php # Dashboard
├── header.php # Navigation & layout
├── database.php # DB connection
├── helpers.php # Utility functions ⭐
├── security_config.php # Security headers ⭐
├── csrf.php # CSRF protection ⭐
├── mail_config.php # Email configuration
│
├── Views (User Interfaces)
├── login.php # Login form
├── signup.php # Registration form
├── profile.php # Profile display
├── profup.php # Profile editor
├── request.php # Admin requests
├── myrequest.php # User requests
├── preview.php # Request preview
├── approve.php # Approval form
├── reqpre.php # Request details
├── reqapp.php # Approve handler
├── reqvad.php # Validate handler
│
├── Handlers (Business Logic)
├── usersig.php # Registration handler
├── userlog.php # Login handler
├── userreg.php # Vehicle registration
├── userrequest.php # Request handler
├── canc.php # Cancel handler
├── chk.php # Check operation
├── review.php # Return handler
│
├── Documentation ⭐
├── README.md # This file
├── CODE_STANDARDS.md # Coding standards
├── ARCHITECTURE.md # System design
├── SECURITY.md # Security policy
├── COMPLIANCE.md # Compliance checklist
├── CONTRIBUTING.md # Contribution guide
├── INSTALLATION.md # Setup guide
├── DEPLOYMENT.md # Deployment guide
├── IMPROVEMENTS.md # Recent changes
│
├── Configuration
├── .env.example # Env template
├── .env # Env (Git ignored)
├── .gitignore # Git ignore rules
├── phpunit.xml # PHPUnit config
├── Dockerfile # Docker config
├── docker-compose.yml # Docker compose
├── composer.json # PHP dependencies
│
└── Tools
├── bootstrap.bundle.min.js # Bootstrap JS
├── jquery.min.js # jQuery
├── naf.png # Logo
├── admin.png # Admin icon
└── driver.png # Driver icon
Comprehensive documentation is available:
| Document | Purpose |
|---|---|
| CODE_STANDARDS.md | PSR-12 compliance, naming conventions, security practices |
| ARCHITECTURE.md | System architecture, technology stack, data flows |
| SECURITY.md | Security features, vulnerability reporting |
| COMPLIANCE.md | 99% compliance verification against standards |
| CONTRIBUTING.md | Contribution guidelines, PR process |
| INSTALLATION.md | Detailed setup instructions |
| DEPLOYMENT.md | Production deployment & CI/CD |
| IMPROVEMENTS.md | Recent improvements & changes |
Edit .env file:
DB_HOST=localhost
DB_USER=root
DB_PASS=
DB_NAME=amvrss
Gmail SMTP example:
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
SMTP_USER=your_email@gmail.com
SMTP_PASS=your_app_password
SMTP_FROM=noreply@amvrs.local
ADMIN_EMAIL=admin@amvrs.local
Database connection in database.php:
$host = "localhost";
$user = "root";
$pass = "";
$db = "amvrss";
$dbh = mysqli_connect($host, $user, $pass, $db);
| Role | Dashboard | Vehicle Requests | Approvals | Admin | View History |
|---|---|---|---|---|---|
| Admin | ✅ Full | ✅ All | ✅ Approve/Reject | ✅ Yes | ✅ All |
| Approver | ✅ Limited | ✅ All | ✅ Approve/Reject | ❌ No | ✅ All |
| Driver | ✅ Personal | ✅ Own Only | ❌ No | ❌ No | ✅ Own Only |
password_hash())htmlspecialchars()X-Content-Type-Options: nosniff
X-Frame-Options: DENY
X-XSS-Protection: 1; mode=block
Content-Security-Policy: Restrictive policy
Referrer-Policy: strict-origin-when-cross-origin
HSTS: Strict-Transport-Security enabled
# Run all tests
php phpunit --configuration phpunit.xml
# Run specific test
php phpunit tests/HelpersTest.php
# PHP syntax check
php -l *.php
# Check all PHP files
find . -name "*.php" -exec php -l {} \;
# Start services
docker-compose up -d
# Access application
# http://localhost:8000
# Stop services
docker-compose down
CREATE TABLE users (
id INT PRIMARY KEY AUTO_INCREMENT,
Full_name VARCHAR(100),
rank VARCHAR(50),
snumber VARCHAR(50) UNIQUE,
email VARCHAR(100) UNIQUE,
username VARCHAR(20) UNIQUE,
password VARCHAR(255),
user_type ENUM('driver', 'admin'),
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);
CREATE TABLE vechicle (
vech_id INT PRIMARY KEY AUTO_INCREMENT,
user_id INT,
vech_name VARCHAR(100),
vech_color VARCHAR(50),
vech_cat VARCHAR(50),
status ENUM('free', 'allocated'),
created_at TIMESTAMP
);
CREATE TABLE request (
id INT PRIMARY KEY AUTO_INCREMENT,
user_id INT,
vech_id INT,
vech_name VARCHAR(100),
mission TEXT,
status ENUM('pending', 'approved', 'rejected', 'returned'),
created_at TIMESTAMP,
FOREIGN KEY (user_id) REFERENCES users(id),
FOREIGN KEY (vech_id) REFERENCES vechicle(vech_id)
);
.env passwords# Build image
docker build -t amvrs-armed .
# Run container
docker run -d -p 8000:80 amvrs-armed
# Push to registry
docker tag amvrs-armed:latest ghcr.io/ajiko2505/amvrs-armed:latest
docker push ghcr.io/ajiko2505/amvrs-armed:latest
See DEPLOYMENT.md for detailed instructions.
Apache License 2.0 - See LICENSE file for details.
We welcome contributions! Please see CONTRIBUTING.md for guidelines on:
| Version | Date | Status | Notes |
|---|---|---|---|
| 1.0.0 | 2026-02-09 | Live | Initial release with security hardening |
| 0.9.0 | 2026-02-01 | Archive | Beta version |
Development Team: AMVRS ARMED Development Team
Architecture: Modern PHP + Bootstrap 5.3 + MySQL
Security: Industry best practices & OWASP guidelines
Testing: PHPUnit + manual QA
Made for Armed Forces Operations 🎖️
| Last Updated: February 9, 2026 | Status: Live & Maintained | License: Apache 2.0 |