Add waiting system application files
- Add main application files (main.py, models.py, schemas.py, etc.) - Add routers for all features (waiting, attendance, members, etc.) - Add HTML templates for admin and user interfaces - Add migration scripts and utility files - Add Docker configuration - Add documentation files - Add .gitignore to exclude database and cache files 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
19
migrate_name_display_length.py
Normal file
19
migrate_name_display_length.py
Normal file
@@ -0,0 +1,19 @@
|
||||
"""Add name_display_length column to store_settings table"""
|
||||
|
||||
from database import SessionLocal, engine
|
||||
from sqlalchemy import text
|
||||
|
||||
db = SessionLocal()
|
||||
try:
|
||||
# Add the column if it doesn't exist
|
||||
db.execute(text("ALTER TABLE store_settings ADD COLUMN name_display_length INTEGER DEFAULT 0"))
|
||||
db.commit()
|
||||
print("✅ Successfully added name_display_length column")
|
||||
except Exception as e:
|
||||
if "duplicate column name" in str(e).lower() or "already exists" in str(e).lower():
|
||||
print("ℹ️ Column already exists, skipping...")
|
||||
else:
|
||||
print(f"❌ Error: {e}")
|
||||
db.rollback()
|
||||
finally:
|
||||
db.close()
|
||||
Reference in New Issue
Block a user