Mobile
Real-time product tracking application for monitoring manufacturing processes with live status updates.
MatQuCon (Material Quality Control) is a comprehensive manufacturing and quality control management system designed for industrial production environments, specifically tailored for electrochemical processes and material handling. The application manages job orders, bath sessions, material inventory, product tracking, and quality measurements in a manufacturing facility.
The system enables manufacturers to track products through their entire lifecycle with QR code integration, monitor electrochemical bath processes with precise measurement recording, and manage material inventory with automatic consumption tracking. It provides role-based access control for different user types and supports real-time status updates through a mobile application.
MatQuCon follows a three-tier architecture with a React Native mobile frontend, Express.js backend API, and PostgreSQL database. The backend follows a Service Layer pattern where routes handle HTTP requests, services contain business logic, and middleware handles cross-cutting concerns like authentication and validation.
graph TB
Mobile[Mobile App<br/>React Native/Expo] -->|HTTP/REST API| Backend[Backend API<br/>Express.js<br/>Port 3000]
Backend -->|SQL Queries| Database[(PostgreSQL<br/>Port 5442)]
Backend -->|QR Generation| QR[QR Code Service]
Mobile -->|QR Scanning| QR
Backend: Node.js, Express.js, PostgreSQL, pg-promise, JWT authentication, bcrypt, nanoid, qrcode
Mobile: React Native, Expo, Expo Router, React Navigation, Zustand, Axios
Database: PostgreSQL with triggers, stored procedures, and complex relational schema
Development: Docker, Docker Compose, Biome linter/formatter
The system implements sophisticated database-level business logic through triggers and stored procedures. A database trigger automatically decrements material inventory when materials are added to bath sessions, preventing negative quantities and ensuring data consistency. The stored procedure for bath history validates that measurements can only be recorded for active bath sessions (not idle baths), enforcing business rules at the database level.
Product tracking uses nanoid to generate unique 8-character alphanumeric codes, which are then converted to QR codes. The QR code endpoint serves a Pug template that displays comprehensive product information including customer firm, job order details, step statuses, bath sessions, materials used, and measurement history. The system supports XML import/export functionality for product categories and complete product history, enabling data migration and reporting.