Skip to content

Repository files navigation


██████╗ ██╗██████╗     ███████╗██╗   ██╗███████╗████████╗███████╗███╗   ███╗
██╔══██╗██║██╔══██╗    ██╔════╝╚██╗ ██╔╝██╔════╝╚══██╔══╝██╔════╝████╗ ████║
██████╔╝██║██████╔╝    ███████╗ ╚████╔╝ ███████╗   ██║   █████╗  ██╔████╔██║
██╔══██╗██║██╔══██╗    ╚════██║  ╚██╔╝  ╚════██║   ██║   ██╔══╝  ██║╚██╔╝██║
██████╔╝██║██║  ██║    ███████║   ██║   ███████║   ██║   ███████╗██║ ╚═╝ ██║
╚═════╝ ╚═╝╚═╝  ╚═╝    ╚══════╝   ╚═╝   ╚══════╝   ╚═╝   ╚══════╝╚═╝     ╚═╝

Bureau of Internal Revenue — Tax Administration Prototype

Version PHP MySQL Apache Status


A full-stack web platform simulating real-world tax administration — built with role-based access, secure authentication, and end-to-end payment workflows.



📌 What Is This?

The BIR Prototype System is a comprehensive, web-based tax administration simulator designed to reflect how a real government tax bureau operates digitally. It supports four distinct user roles — each with its own dashboard, permissions, and workflows — and handles everything from tax form submission to bank payment approvals and receipt verification.

This prototype demonstrates production-ready thinking: secure OTP authentication, audit trails, financial upload handling, and a modular codebase built for maintainability.


🧩 System Architecture at a Glance

┌─────────────────────────────────────────────────────────────┐
│                     BIR PROTOTYPE SYSTEM                    │
├──────────────┬──────────────┬──────────────┬────────────────┤
│    ADMIN     │ BIR EMPLOYEE │     BANK     │   TAXPAYER     │
│  Dashboard   │  Dashboard   │   Portal     │   Dashboard    │
│  User Mgmt   │  Daily Ops   │  Payment     │   Tax Filing   │
│  Reports     │  Form Review │  Approval    │   History      │
│  Audit Logs  │  Submissions │  Transactions│   Uploads      │
└──────┬───────┴──────┬───────┴──────┬───────┴───────┬────────┘
       │              │              │               │
       └──────────────┴──────┬───────┴───────────────┘
                             │
              ┌──────────────▼──────────────┐
              │     PHP + MySQL Backend      │
              │  Auth · Tax Engine · OTP    │
              │  File Handler · Audit Log   │
              └─────────────────────────────┘

✨ Core Features

Feature Description
🔐 Role-Based Access Control Separate portals for Admin, BIR Employee, Bank, and Taxpayer
🛡️ OTP Authentication Two-factor login verification and secure password reset
🧾 Tax Form Management Complete form submission, review, and approval pipeline
💳 Bank Payment Integration End-to-end payment processing with bank approval workflow
🧮 Tax Calculation Engine Automated computation via taxcalc.js
📂 Financial Statement Uploads Validated file handling for financial data submission
Receipt Verification Traceable payment receipts with verification system
📊 Admin Reporting Report generation and login history for full audit visibility
🔒 HTACCESS Security Route protection, URL rewriting, and directory access control

🎬 Video Documentation

All workflows are fully documented. Click any section to watch the walkthrough.

🎥 1 — Admin Approval Workflows
Walkthrough of admin approval workflows for forms and user submissions.
admin_approval.mp4
🎥 2 — Administrator Dashboard & Reporting
Overview of the administrator dashboard, user management, and reporting tools.
admin_dashboard.mp4
🎥 3 — Bank Payment Approval Process
Guide to bank payment approval and transaction submission processes.
bank_dashboard.mp4
🎥 4 — Tax Calculation & Receipt Verification
Technical walkthrough of system components, tax calculation, and receipt verification.
Code_Section.mp4
🎥 5 — BIR Employee Dashboard
BIR employee official dashboard and daily operations guide.
employee_dashboard.mp4
🎥 6 — Password Recovery & OTP Workflow
Complete password recovery workflow including OTP sending and verification.
forgot_password.mp4
🎥 7 — New User Registration
New user registration process and account creation guide.
signup.mp4
🎥 8 — Taxpayer Dashboard & Filing
Taxpayer dashboard navigation, tax filing, payment history, and financial uploads.
userboard.mp4

🛠️ Technology Stack

Frontend          │  HTML5 · CSS3 · JavaScript
                  │  PasswordLogic.js · taxcalc.js · financials.js
──────────────────┼───────────────────────────────────────────────
Backend           │  PHP
──────────────────┼───────────────────────────────────────────────
Database          │  MySQL  (managed via db.php)
──────────────────┼───────────────────────────────────────────────
Server            │  Apache with mod_rewrite + HTACCESS
──────────────────┼───────────────────────────────────────────────
Package Manager   │  Composer
──────────────────┼───────────────────────────────────────────────
Configuration     │  .env file (environment-separated secrets)

🚀 Installation Guide

Prerequisites

  • Apache server with mod_rewrite enabled (XAMPP / WAMP recommended)
  • PHP 7.4+
  • MySQL 5.7+
  • Composer

Step-by-Step Setup

1. Clone the repository

git clone https://github.com/your-username/bir-prototype.git
cd bir-prototype

2. Configure environment variables

cp .env.example .env
# Edit .env with your database credentials and settings

3. Install PHP dependencies

composer install

4. Set up the database

-- Import the provided SQL schema into your MySQL server
-- Then verify db.php points to the correct credentials

5. Set file permissions

chmod 775 uploads/
# Ensure the uploads/ folder is writable by your web server

6. Launch the application

http://localhost/bir-prototype/Admin/index.php

🔒 Security Highlights

  • HTACCESS — Restricts direct access to sensitive directories and handles secure route rewriting
  • OTP Verification — Two-step password recovery prevents unauthorized account access
  • Common Password BlacklistCommon_Password.txt enforces strong password policies
  • File Upload Validation — Uploaded financial documents are type-checked and securely stored
  • Environment Variable Isolation — All secrets kept out of source code via .env
  • Login History Tracking — Full audit trail of user authentication events


🗺️ Roadmap

  • Role-based authentication with OTP
  • Tax form submission & approval workflow
  • Bank payment integration
  • Receipt verification system
  • Admin reporting & audit logs
  • Email notifications for workflow events
  • API layer for mobile client support
  • Enhanced analytics dashboard
  • Docker containerization for deployment

🤝 Contributing

Contributions, issues, and feature requests are welcome. Please open an issue first to discuss what you would like to change.


📄 License

This project is a prototype built for demonstration and educational purposes.


Built with care · BIR Prototype System v1.0

For technical issues or feature requests, contact the system administrator.

About

A BIR tax system prototype developed as an OJT project for the Bureau of Internal Revenue (BIR) Pangasinan. The platform includes multi-role dashboards, OTP-secured authentication, tax calculation, payment approval workflows, and complete video documentation for all major functionalities.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages