Initial Switch to V2. Completely Overhauled Backend, Frontend and General Structure.

This commit is contained in:
2026-04-17 14:37:36 +03:00
parent eb773c5531
commit 0a8a42d69b
447 changed files with 70696 additions and 492 deletions

26
backend/settings/orm.py Normal file
View File

@@ -0,0 +1,26 @@
from datetime import datetime, timezone
from sqlalchemy import Column, DateTime, String, Text
from sqlalchemy.dialects.postgresql import JSONB
from database.postgres import Base
def _now():
return datetime.now(timezone.utc)
class ConsoleSetting(Base):
"""Key/value store for console configuration (replaces Firestore 'settings' doc)."""
__tablename__ = "console_settings"
key = Column(String(128), primary_key=True)
value = Column(JSONB) # any JSON value
updated_at = Column(DateTime(timezone=True), nullable=False, default=_now, onupdate=_now)
class PublicFeature(Base):
"""Public-facing feature flags and configuration (replaces Firestore 'public_features' doc)."""
__tablename__ = "public_features"
key = Column(String(128), primary_key=True)
value = Column(JSONB)
updated_at = Column(DateTime(timezone=True), nullable=False, default=_now, onupdate=_now)