Files
inventree-stock-tool/pyproject.toml
grabowski 03b7a4b0c8 feat: Add web application interface
Implements a modern web-based interface alongside the existing desktop app.

Features:
- Flask backend with REST API and WebSocket support
- Responsive web UI with TailwindCSS and Alpine.js
- Real-time updates via Socket.IO
- All desktop features available in browser
- Multi-user support
- Mobile-friendly responsive design
- Same async import queue functionality

Technology Stack:
- Backend: Flask + Flask-SocketIO + Flask-CORS
- Frontend: HTML5 + TailwindCSS + Alpine.js
- Real-time: WebSocket (Socket.IO)
- Icons: Font Awesome 6

New Files:
- src/stocktool/web/app.py - Flask application server
- src/stocktool/web/templates/index.html - Main web interface
- src/stocktool/web/static/js/app.js - Alpine.js application logic
- WEB_APP.md - Complete web app documentation

API Endpoints:
- GET /api/config - Application configuration
- GET /api/locations - List locations
- POST /api/part/search - Search for part
- POST /api/part/import - Queue part import
- POST /api/stock/add - Add stock
- POST /api/stock/update - Update stock
- POST /api/stock/check - Check stock level
- POST /api/part/locate - Locate part
- GET /api/pending - Get pending imports

WebSocket Events:
- import_complete - Part import finished
- import_retry - Import failed, retrying
- import_failed - Import failed completely
- barcode_parsed - Barcode successfully parsed

Benefits:
- Access from any device with a browser
- No desktop installation required
- Better mobile experience
- Multiple users can work simultaneously
- Easier deployment and updates
- Network-accessible within local network

Usage:
  uv run stock-tool-web
  # Open browser to http://localhost:5000

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 11:20:22 +07:00

34 lines
773 B
TOML

[project]
name = "stocktool"
version = "2.0.0"
description = "InvenTree Stock Management Tool - A comprehensive barcode scanning application for InvenTree inventory management"
authors = [
{name = "InvenTree Stock Tool Contributors"}
]
requires-python = ">=3.9"
dependencies = [
"sv-ttk>=2.0.0",
"pillow>=10.0.0",
"requests>=2.31.0",
"pyyaml>=6.0.0",
"flask>=3.0.0",
"flask-socketio>=5.3.0",
"flask-cors>=4.0.0",
]
readme = "README.md"
license = {text = "MIT"}
[project.scripts]
stock-tool = "stocktool.stock_tool_gui_v2:main"
stock-tool-web = "stocktool.web.app:main"
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["src/stocktool"]
[tool.uv]
dev-dependencies = []