🚧 Status: Under Development This is an internal project built specifically for TGNJ and serves as a personal learning initiative to explore Python-based desktop application architecture.
TGNJ Inventory Manager is a lightweight, local-first application designed to track and manage itemized stone data. Rather than using complex spreadsheets or cloud-based SaaS, this tool provides a dedicated, searchable interface that runs entirely on your local machine.
- Hybrid Desktop Apps: Using
pywebviewto bridge a Flask/web backend with a native window. - Database Optimization: Implementing SQLite Write-Ahead Logging (WAL) for faster performance on local drives.
- Modern Tooling: Mastering
uvfor lightning-fast, reproducible Python environments.
- Language: Python 3.12+
- Backend: Flask (RESTful API)
- Database: SQLite (Optimized with WAL mode)
- Frontend: HTML5, CSS3, JavaScript (Jinja2 Templates)
- Container: PyWebview
- Environment: uv
This project is cross-platform (Windows, macOS, Linux). You will need Python installed. We highly recommend using uv for dependency management.
Clone the repository and install dependencies using uv:
git clone [https://github.com/your-username/tgnj-app.git](https://github.com/your-username/tgnj-app.git)
cd tgnj-app
You don't need to manually set up a virtual environment; uv handles it automatically:
uv run src/tgnj_app/main.py
tgnj-app/
├── src/
│ └── tgnj_app/
│ ├── core/ # Database wrapper & SQL logic
│ ├── gui/ # Flask API, CSS, and Templates
│ │ ├──
│ └── main.py # Application entry point & window launch
├── pyproject.toml # Project metadata & dependencies
└── README.md
The GUI communicates with a local Flask server via these endpoints:
| Method | Endpoint | Description |
|---|---|---|
GET |
/api/getData/<group> |
Fetch items by SKU group. |
POST |
/api/addItem |
Add a new item to the database. |
DELETE |
/api/deleteItem/<id> |
Remove an item from inventory. |
- Implement bulk CSV import for legacy data.
- Add image upload support for stone identification.
- Refine CSS for better high-DPI display support.
- Automated local database backups.