How priyagaggar/threadcontrol works
ThreadControl is a textile-production ERP whose main workflow tracks material from raw-material intake through softening, dyeing, winding, packing, and dispatch. Factory staff enter production data; supervisors approve entries before they affect stock. The application also provides live balances, audit and reporting tools, and administrative features. Its documented platform combines a browser app, a Cloudflare Worker, Firebase Realtime Database, and R2 backups. Relationships below rely on README descriptions; no source excerpts were provided, so implementation-level call paths cannot be verified.
Main entry points: worker.js Cloudflare backend · soft.js Softening entries · dye.js Dye lot management · wind.js Winding entries
Components 24
Production workflow
- Raw material intake
assets/js/rm.js - Softening entries
assets/js/soft.js - Dye lot management
assets/js/dye.js - Winding entries
assets/js/wind.js - Packing entries
assets/js/pack.js - Dispatch
assets/js/dispatch.js
Operations and oversight
- Approval queue
assets/js/approval.js - Live stock view
assets/js/stock.js - Dashboard
assets/js/dashboard.js - Analytics and reports
assets/js/analytics.js - Edit audit trail
assets/js/editlog.js
Application foundation
- SPA shell
assets/index.html - Page router
assets/js/pages.js - App state and loading
assets/js/core.js - Balance calculations
assets/js/shared-balances.js - Incremental loading
assets/js/smart-loader.js - Summary loading
assets/js/summary-loader.js - Offline persistence
assets/js/idb-storage.js
Backend and storage
- Cloudflare backend
worker.js - Firebase database
- R2 backups
- Offline service worker
assets/sw.js
Other components
- Factory staff
- Supervisor
Connections 18
- Factory staff → Raw material intake: records intake
README.md - Factory staff → Softening entries: records entries
README.md - Factory staff → Dye lot management: manages lots
README.md - Factory staff → Winding entries: records entries
README.md - Factory staff → Packing entries: records entries
README.md - Factory staff → Dispatch: records dispatch
README.md - Raw material intake → Softening entries: production stage
README.md - Softening entries → Dye lot management: production stage
README.md - Dye lot management → Winding entries: production stage
README.md - Winding entries → Packing entries: production stage
README.md - Packing entries → Dispatch: production stage
README.md - Supervisor → Approval queue: reviews entries
README.md - Approval queue → Live stock view: approves stock changes
README.md - SPA shell → Page router: hosts app
README.md - Cloudflare backend → Firebase database: uses database
README.md - Cloudflare backend → R2 backups: stores backups
README.md - Cloudflare backend → Firebase database: refreshes summaries
README.md - Offline service worker → SPA shell: supports offline use
README.md