- Added printed_labels column (INT(1) DEFAULT 0) for print tracking
- Added data_livrare column (DATE NULL) for delivery dates from CSV
- Added dimensiune column (VARCHAR(20) NULL) for product dimensions
- Updated documentation to explain new columns and their purpose
This keeps the setup script synchronized with the actual database structure
that has been modified during development and testing.
✨ New Features:
- Added view_orders route with proper table display
- Implemented CSV upload with preview workflow and date parsing
- Added production WSGI server configuration with Gunicorn
- Created comprehensive production management scripts
🔧 Bug Fixes:
- Fixed upload_data route column mapping for actual CSV structure
- Resolved print module database queries and template rendering
- Fixed view orders navigation routing (was pointing to JSON API)
- Corrected barcode display width constraints in print module
- Added proper date format parsing for MySQL compatibility
🎨 UI/UX Improvements:
- Updated view_orders template with theme-compliant styling
- Hidden barcode text in print module preview for cleaner display
- Enhanced CSV upload with two-step preview-then-save workflow
- Improved error handling and debugging throughout upload process
🚀 Production Infrastructure:
- Added Gunicorn WSGI server with proper configuration
- Created systemd service for production deployment
- Implemented production management scripts (start/stop/status)
- Added comprehensive logging setup
- Updated requirements.txt with production dependencies
📊 Database & Data:
- Enhanced order_for_labels table compatibility
- Fixed column mappings for real CSV data structure
- Added proper date parsing and validation
- Improved error handling with detailed debugging
🔧 Technical Debt:
- Reorganized database setup documentation
- Added proper error handling throughout upload workflow
- Enhanced debugging capabilities for troubleshooting
- Improved code organization and documentation
- Created virtual environment and installed requirements
- Set up MariaDB database with user 'sa' and database 'recticel'
- Created order_for_labels table for printing functionality
- Implemented role-based permissions system with admin role
- Added admin access to print label modules and etichete functionality
- Fixed template routing issues in main_page_etichete.html
- Updated app to run on port 8781 with network access (0.0.0.0)
- Added systemd service file for background deployment
- Created installation documentation
The CSS class 'show' was being overridden by global styles causing display:block instead of display:flex. Using inline style.display='flex' to force the modal to show properly with flexbox centering.
Changes:
- Added modal.style.display = 'flex' when showing modal
- Added modal.style.display = 'none' when hiding modal
- Added debug logging for inline style verification
- This ensures modal displays regardless of CSS conflicts
- Made print button handler async and await handleQZTrayPrint
- Added console.log debugging to track modal element and class changes
- This should fix the modal not appearing during print operations
Features:
- Real-time progress modal with visual progress bar and counter
- Detailed event log with timestamps and color-coded status
- Pause/Resume functionality for checking printer/paper
- Reprint Last button for damaged labels
- Cancel button for emergency stops
- Automatic error detection and recovery
- Auto-pause on print failures (paper out/jam)
- Automatic retry of failed labels after resume
- Smart state management tracking current/last/failed labels
- Sequential label numbering maintained through errors
- Database update only on successful completion
- Proper modal display with .show class toggle